I'm using statsmodels.tsa.SARIMAX() to train a model with exogenous variables. Is there an equivalent of get_prediction() when a model is trained with exogenous variables so that the object returned contains the predicted mean and confidence interval rather than just an array of predicted mean results? The predict() and forecast() methods take exogenous variables, but only return the predicted mean value.
SARIMA_model = sm.tsa.SARIMAX(endog=y_train.astype('float64'),
exog=ExogenousFeature_train.values.astype('float64'),
order=(1,0,0),
seasonal_order=(2,1,0,7),
simple_differencing=False)
model_results = SARIMA_model.fit()
pred = model_results.predict(start=train_end_date,
end=test_end_date,
exog=ExogenousFeature_test.values.astype('float64').reshape(343,1),
dynamic=False)
pred here is an array of predicted values rather than an object containing predicted mean values and confidence intervals that you would get if you ran get_predict(). Note, get_predict() does not take exogenous variables.
My version of statsmodels is 0.8