# Forecasting with ARMAX vs. Regression with ARMA errors

In this post Rob Hyndman says that for forecasting, it doesn't matter whether we fit an ARMAX model or an OLS model with ARMA errors: https://robjhyndman.com/hyndsight/arimax/

Why is that the case? Suppose an ARMAX(1, 0). Then to forecast with it we have

$$E[y_t | x_t, y_{t-1}] = \beta x_t + \phi y_{t-1}$$

If we fit an OLS model with ARMA errors the forecast becomes

$$E[y_t | x_t, y_{t-1}] = \beta x_t$$

since the lags of $$y_t$$ are not in the model.

I'm interested in both the forecasts for $$E[y_t]$$ and for one specific $$y_t$$.

• In Hyndman's forecast package, the ARMAX model is fitted sequentially as an OLS model with ARMA errors. It isn't a "true" ARMAX model in the Box-Jenkins sense of the term. You can use the function in the TS package if you want the "true" ARMAX model. Look at the last few paragraphs on the page you have linked to for a more detailed explanation. (Also, he doesn't say it doesn't matter, he says he prefers to fit the sequential model, and that's what he does in the forecast package. – jbowman Nov 8 '18 at 21:52
• Your computation of the conditional expectation in the regression-with-ARMA-errors model is wrong (the conditional expectation of the error term is not zero). – Chris Haug Nov 8 '18 at 22:43