ARIMA, short for autoregressive integrated moving average, is a family of statistical models used to describe and forecast a time series. An ARIMA model explains the current value of a series using its own earlier values and the errors made by earlier forecasts, after the series has been differenced enough times to remove any trend. It is one of the standard tools of time series analysis.
The approach was set out by George Box and Gwilym Jenkins in their 1970 book on forecasting, and the fitting routine they described is still called the Box-Jenkins method. In finance, ARIMA is used for series such as trading volumes, interest rate spreads, economic indicators and the gap between two related prices. It is also the usual baseline against which more complex forecasting models are judged.
The three parts of the model
An ARIMA model is written ARIMA(p, d, q), where each letter is a whole number chosen by the analyst.
- Autoregressive part (p). The series is regressed on its own previous p values. This is autoregression, and it captures persistence: a high value tends to be followed by another high value, or by a low one if the coefficient is negative.
- Integrated part (d). The series is differenced d times, meaning each value is replaced by its change from the previous value. Differencing turns a trending series into one that satisfies stationarity, which the other two parts require.
- Moving average part (q). The current value depends on the previous q forecast errors. Despite the name, this is unrelated to the moving average drawn on a price chart; it is a weighted sum of past random shocks.
Formula and example
After differencing, the model for the differenced series is:
- is the differenced series at time (for , today's value minus yesterday's).
- is a constant.
- are the autoregressive coefficients and are the moving average coefficients.
- is the random error, or shock, at time , assumed to have zero mean and constant variance.
Take an ARIMA(1, 1, 0) model with and . A spread stood at 100 two days ago and 102 yesterday, so the latest change is 2. The forecast for today's change is 0.5 × 2 = 1, and the forecast level is 102 + 1 = 103. If the coefficient were zero, the forecast would simply be yesterday's level, which is the random walk forecast.
Fitting a model
The Box-Jenkins method has three steps. First comes identification. The analyst checks whether the series is stationary, often with the augmented Dickey-Fuller test, and differences it if not. Plots of the autocorrelation and partial autocorrelation functions then suggest values for p and q. Second, the coefficients are estimated, normally by maximum likelihood. Third, the residuals are checked. If the model is adequate, they should show no remaining pattern.
Software can search over many combinations of p, d and q and pick the one with the best information criterion, a score that rewards fit and penalizes extra parameters. The penalty matters because a model with many terms can fit history closely and still forecast badly, a form of overfitting. Forecasts are best judged on data that was not used for fitting.
Use in financial markets
Daily returns on liquid assets show very little autocorrelation, so an ARIMA model of prices usually reduces to something close to a random walk. That result is consistent with the efficient market hypothesis in its weak form. The model is more useful on series that do have structure. Trading volume, bid-ask spreads and realized volatility are persistent and can be forecast to a useful degree. The spread between two cointegrated assets in pairs trading is often modeled as a low-order autoregressive process, and its estimated speed of mean reversion guides how long a position is expected to be held.
Central banks, treasury desks and economists use ARIMA and its seasonal extension, SARIMA, for inflation, cash flows and similar series. In time series forecasting competitions, simple ARIMA models have often matched far more elaborate methods on short series.
Limitations
ARIMA is a linear model with a constant error variance. Financial returns break the second assumption: quiet and turbulent periods cluster together. Models of the GARCH family were built to describe that changing variance and are often combined with an ARIMA model for the mean. ARIMA also uses only the series itself, so it ignores outside information, and it assumes the same structure holds through time. A change in policy, market rules or regime can make coefficients estimated on old data misleading. Nonlinear methods, including the long short-term memory network, are used where those limits bind, though they need much more data.