The lag-k autocorrelation, ρ(k), measures the link between today’s return and the return k periods ago. ρ(1) > 0: moves tend to continue (momentum). ρ(1) < 0: they tend to reverse (mean reversion).
Under the random walk hypothesis, the standard error of ρ(k) is about 1/√N. With N = 2,500 sessions: 1/50 = 0.02. An autocorrelation is only significant at 95% beyond ±2/√N = ±0.04. The Ljung-Box test checks several lags at once.
The weak form of market efficiency (Fama, 1970) says past prices cannot beat the market after costs. Returns are barely autocorrelated, but their absolute values strongly are: this is volatility clustering, useful for risk management, not for predicting direction.
To test it, you compute the correlation between the series and itself shifted by one session, then apply Ljung-Box over, say, 10 lags. Trap: ρ(1) = −0.03 can be significant over 20 years of data and earn nothing once the spread is paid. A negative ρ(1) can also come from the simple bid-ask bounce: prices alternate between the bid and the ask.
Examples
AUTO-X (fictional market) : Over 2,500 sessions of AUTO-X (fictional market), ρ(1) = −0.06, beyond the ±0.04 threshold. Daily volatility: 1%. After a 1% drop, the next day’s expected return is −0.06 × (−1%) = +0.06%, i.e. 6 bp. With 10 bp of round-trip costs, the statistical edge disappears: significant does not mean profitable.
1988: Lo and MacKinlay and the random walk : In “Stock Market Prices Do Not Follow Random Walks” (Review of Financial Studies, 1988), Andrew Lo and Craig MacKinlay used the variance ratio test and rejected the random walk for weekly returns of US indices, which were positively autocorrelated, especially among small caps. Lesson: a real anomaly is not necessarily tradable; part of it comes from the poor liquidity of small stocks, whose prices react with a lag.
Key terms
Autocorrelation
Correlation of a series with its own past values
Random walk
Process whose future changes cannot be predicted from the past
Ljung-Box test
Joint test for no autocorrelation across several lags
Volatility clustering
Tendency of large moves to follow large moves, and small ones small ones
Basis point (bp)
One hundredth of a percent: 10 bp = 0.10%
Bid-ask bounce
Mechanical alternation of prices between the bid and the ask