- OLSResults.predict(exog=None, endog=None, *, data=None, fitted=True, idiosyncratic=False, missing=False)¶
In- and out-of-sample predictions
Exogenous values to use in out-of-sample prediction (nobs by nexog)
Endogenous values to use in out-of-sample prediction (nobs by nendog)
DataFrame to use for out-of-sample predictions when model was constructed using a formula.
Flag indicating whether to include the fitted values
Flag indicating whether to include the estimated idiosyncratic shock
Flag indicating to adjust for dropped observations. If True, the values returned will have the same size as the original input data before filtering missing values. If False, then missing observations will not be returned.
DataFrame containing columns for all selected outputs
If exog, endog and data are all None, in-sample predictions (fitted values) will be returned.
If data is not none, then exog and endog must be none. Predictions from models constructed using formulas can be computed using either exog and endog, which will treat these are arrays of values corresponding to the formula-process data, or using data which will be processed using the formula used to construct the values corresponding to the original model specification.
- Return type