Statistics Quest

Autocorrelation (ACF) and partial autocorrelation (PACF)

The correlation of a series with its own past at each lag (ACF), and the same after removing the effect of shorter lags (PACF), used to detect dependence, seasonality and AR order.

rk=ckc0,ck=1n∑t=1n−k(yt−yˉ)(yt+k−yˉ)r_k = \frac{c_k}{c_0}, \qquad c_k = \frac{1}{n}\sum_{t=1}^{n-k}(y_t - \bar y)(y_{t+k} - \bar y)
Sample autocorrelation at lag k (biased autocovariance, divisor n)
kk
lag (number of periods apart)
nn
length of the series
yˉ\bar y
mean of the whole series
±z0.975n≈±1.96n\pm \frac{z_{0.975}}{\sqrt{n}} \approx \pm\frac{1.96}{\sqrt{n}}
Approximate 95% limits for white noise
nn
length of the series

When to use

  • Checking whether a series (or a model's residuals) is white noise; spotting seasonality (spikes at lags m,2m,…m, 2m, \ldots); choosing an AR order.
  • The PACF at lag kk is the last coefficient ϕkk\phi_{kk} of an AR(kk) fitted to the series (computed by the Durbin–Levinson recursion on the ACF).

Assumptions

  • Equally spaced observations with no missing values; the series should be roughly stationary (trend removed or differenced) for the ACF to be interpretable.
  • The ±1.96/√n bands assume white noise and apply lag by lag; with many lags, about 1 in 20 will cross by chance.

How to interpret

  • Slowly decaying ACF: trend or non-stationarity — difference the series.
  • AR(p): PACF cuts off after lag pp, ACF decays gradually.
  • For residuals, a joint check such as the Ljung–Box test Q=n(n+2)∑k=1hrk2/(n−k)Q = n(n+2)\sum_{k=1}^{h} r_k^2/(n-k) complements the plot.

Common mistakes

  • Interpreting a single bar that just crosses the band as a real pattern.
  • Reading the ACF of a trending series as "strong dependence" rather than non-stationarity.
  • Expecting reliable ACFs from very short series (the bands are wide).

Example

Series 3, 5, 4, 6, 5, 7, 6, 8 (n=8n = 8): r1=0.125r_1 = 0.125, r2=0.472r_2 = 0.472, r3=−0.236r_3 = -0.236; PACF at lag 2 = 0.464. The white-noise band is ±1.96/√8 = ±0.693, so no lag is clearly significant — eight points are too few to say much.