# How to check adequacy of a time series model using residual autocorrelations?

This was in an past exam question I came across.

A first-order autoregressive model has been fitted to a time series of 50 observations giving $\hat\mu = 15$ and $\hat\alpha =0.6$.

The first 12 residual autocorrelations were given and the estimated standard deviation of $r_k(\hat Z_t)=0.15$ $k=1,2...12.$ The question was to check the adequacy of the fitted model. The only adequacy test we were given was the Ljung-Box test which I think uses sample autocorrelations, not residual autocorrelations.

• To use the Ljung-Box test on residuals rather than the original time series you just need to adjust the statistic's degrees of freedom to take account of the number of fitted parameters. – Scortchi - Reinstate Monica Jun 26 '13 at 16:42

The Ljung-Box test (or Chi-squared test) tests the following null hypothesis: \begin{equation} H_{0}: \rho_{1}(a) = \rho_{2}(a) = \cdots = \rho_{K}(a) = 0 \end{equation} where $\rho_{K}(a)$ denotes the residual autocorrelation at lag K.

The test statistic is: \begin{equation} Q^{*} = n (n + 2) \sum_{k=1}^{K}(n- k)^{-1} r_{k}^{2}(\hat{a}) \end{equation} where $n$ is the number of observations used to estimate the model, $K$ is the number of residual autocorrelations, and $r_{k}(\hat{a})$ is the residual autocorrelation function.

The $Q^{*}$ statistic follows a chi-squared distribution with $(K-m)$ degrees of freedom, where $m$ is the number of parameters estimated in the ARIMA model.

• With 50 observations, $n = 49$ (because the number of residuals associated with an AR(1) model is: $\text{number of observations} - 1$).
• With 12 residual autocorrelations, $K = 12$.
• With two estimated parameters, $\hat{\mu}$ and $\hat{\alpha}$, $m= 2$.

Does this provide you with enough help?

• Thanks a lot! it does, but does the Ljung-Box test's test statistic always use residual autocorrelations or is it time series autocorrelations? And also expect the Ljung-Box test is there any other adequacy tests which could be done using the given data? Thanks again – Infinity Jun 26 '13 at 18:11
• The test can be applied to any group of autocorrelations of a time-series; they need not be residual autocorrelations, but at the diagnostic checking stage of ARIMA analysis, they would be. Well, the test tests the autocorrelations as a set, so an alternative (or complement!) would be to use a t-test to test the autocorrelations individually. A related test to the Ljung-Box test is called the Box-Pierce test, but the Ljung-Box test is often preferred to the Box-Pierce. – Graeme Walsh Jun 26 '13 at 18:21
• (cont...) some other adequacy tests are: 1) plot the residuals 2) try overfitting 3) fit subsets of the data. 1) Eyeball the plot for changing variance (if found, transform the data, e.g. take logs). 2) Fit an AR(2), that is, overfit the AR(1) model. Do this if at the identification stage an AR(2) seemed plausible. Based on the AR(2) results, decide if the more parsimonious model, the AR(1), is adequate. 3) Split the data 50-50 and test if the estimated coefficients are statistically different (t-test). Also check if the coefficients differ by more than, say, 0.1 in magnitude. Hope this helps. – Graeme Walsh Jun 26 '13 at 18:31
• @Infinity Check the edit I made to my answer. I changed n = 50 to n = 49. Why? 1) The number of observations used to estimate the AR(1) is 50. 2) Thus, the number of residuals is 49. 3) The "first" residual is n.a. To see this consider data at t=1,2,...,50. An AR(1) is $z_{t} = \mu + \alpha_{1} z_{t-1} + a_{t}$ and to calculate the residuals use $\hat{z}_{t} = \hat{\mu} + \hat{\phi}_{1} z_{t-1}$. Notice that we do not calculate $\hat{z_{1}}$ because in that case we have $\hat{z}_{1} = \hat{\mu} + \hat{\phi}_{1} z_{0}$ and data is not available for t=0. Note again that the data starts at t=1. – Graeme Walsh Jun 27 '13 at 6:43