statsmodels.tsa.vector_ar.var_model.VAR.predict#

VAR.predict(params, start=None, end=None, lags=1, trend='c')[source]#

Returns in-sample predictions or forecasts

Parameters:
paramsndarray

The parameters/coefficients of the VAR model, in the same format as VARResults.params.

startint, str, or datetime, optional

Zero-indexed observation number at which to start forecasting, i.e., the first forecast is start.

endint, str, or datetime, optional

Zero-indexed observation number at which to end forecasting, i.e., the last forecast is end.

lagsint

The number of lags used in the model.

trendstr {“n”, “c”, “ct”, “ctt”}

The deterministic trend used in the model.

Returns:
ndarray

Array of in-sample predicted values and/or out-of-sample forecasts.