Serial Correlation: Consequences, Diagnosis, and Robust Inference#
A growth analyst at an e-commerce firm, Amazon-style, runs an OLS regression of weekly sales on weekly ad spend, using two years of data (104 weeks). The ad-spend coefficient is statistically significant. A colleague reruns the regression asking the software for a different kind of standard error, and the \(t\)-statistic drops by almost half. The two regressions use exactly the same data and give exactly the same point estimate. Which one should we trust?
Estimate of \(\beta_1\) |
Standard error |
\(t\)-statistic |
95% CI |
|
|---|---|---|---|---|
OLS, conventional standard error |
0.347 |
0.094 |
3.68 |
[0.16 ; 0.53] |
OLS, robust standard error (Newey-West) |
0.347 |
0.178 |
1.95 |
[−0.003 ; 0.70] |
(Simulated data: weekly sales and ad spend in thousands of dollars, with a true effect of \(\beta_1 = 0.35\). This is a single sample; in section 3 we repeat the exercise thousands of times to see that it is not a fluke.)
The difference is not an implementation detail. It stems from a piece of the model we have so far taken for granted: that the errors of different observations are independent of each other. When the data form a time series, that assumption is often hard to defend: what our variables do not explain (brand inertia, the momentum of an earlier campaign, seasonality, a competitor’s promotion) does not vanish from one week to the next. The errors of neighboring weeks resemble each other. We call this serial correlation (or autocorrelation).

In the left panel the residuals form “runs”: several consecutive weeks above the line, then several consecutive weeks below it. In the right panel, with independent errors of the same dispersion, the signs alternate with no pattern. The data span 104 weeks, but the runs suggest they hold much less independent information than 104 observations would.
This section follows the same path as the one on heteroscedasticity: what OLS preserves and what breaks when the assumption fails, how to detect the problem, and how to restore valid inference. We will see that point estimates remain unbiased, but that conventional standard errors can be far more optimistic than they should be, and that there is one case, when the lagged dependent variable enters as a regressor, in which the problem stops being the standard error and becomes the estimator itself.
1. Objectives#
By the end of this section, you will understand:
What serial correlation is, where it comes from, and how it is represented by an AR(1) process.
What OLS preserves and what breaks when errors are correlated over time, and why the “effective sample size” is smaller than \(T\).
When the damage is large: it depends on the product of the error persistence and the regressor persistence, and highly persistent series can generate spurious relationships.
How to detect serial correlation using residual plots, the autocorrelation function, and the Durbin-Watson and Breusch-Godfrey tests, and why it can be a symptom of a misspecified model.
How to restore inference with Newey-West (HAC) standard errors, how it relates to clustered errors, and when it is also worth modeling the dynamics (feasible GLS, lags).
Why a lagged dependent variable as a regressor, combined with serially correlated errors, makes OLS inconsistent.
2. What Is Serial Correlation?#
When we derived the variance of \(\hat{\beta}_1\) in the section on statistical properties of OLS, we assumed that the errors of different observations are uncorrelated with each other: \(\text{Cov}(\varepsilon_t, \varepsilon_s) = 0\) for \(t \neq s\). Serial correlation is the violation of that assumption: the errors of nearby periods are related.
The simplest model to represent it is the first-order autoregressive process, AR(1):
where \(u_t\) is independent noise with variance \(\sigma_u^2\). The parameter \(\rho\) measures the persistence of the errors: if \(\rho > 0\), a positive error tends to be followed by another positive one; if \(\rho < 0\), signs tend to alternate. This process implies that the correlation between errors \(s\) periods apart decays geometrically, \(\text{Corr}(\varepsilon_t, \varepsilon_{t-s}) = \rho^{s}\), and that its variance is \(\text{Var}(\varepsilon_t) = \sigma_u^2/(1-\rho^2)\).
Where does that persistence come from? Almost always from omitted factors that move slowly: brand awareness, the momentum of a previous campaign, seasonality (Prime Day, year-end), a product launch, competitors’ behavior. If those factors are not in the model, they end up in the error, and since they change slowly, this week’s error resembles last week’s. It can also arise when the model omits the dynamics of the phenomenon itself. In section 5 we come back to this: not all serial correlation should be “fixed” with statistical tools; sometimes it signals a missing variable.
Throughout we maintain one important assumption: the regressors are strictly exogenous, meaning \(x_t\) is uncorrelated with every \(\varepsilon_s\), past, present, or future. Later we will see what happens when that assumption fails in a very common way: by including \(y_{t-1}\) as a regressor.
3. Exploring the Consequences via Simulation#
Let us again put ourselves in the position of someone who knows the truth. The following simulation generates the weekly history of a business where sales depend on advertising with a known true effect, \(\beta_1 = 1.5\), and where the errors follow an AR(1) with persistence \(\rho_\varepsilon\) (the momentum of omitted factors). Ad spend is also persistent, with persistence \(\rho_x\) (budgets are planned in blocks). We repeat that history 2,000 times, estimate by OLS in each one, and examine the distribution of the estimates. Before reading the formal results, explore the dashboard with four questions in mind:
Leave \(\rho_x = 0\) and raise \(\rho_\varepsilon\). Does anything change in the distribution of \(\hat{\beta}_1\), or in the coverage of the confidence intervals?
Now raise \(\rho_x\) too. What happens to the ratio between the conventional standard error and the true dispersion of \(\hat{\beta}_1\), and to the coverage? Look at the coverage heatmap: at which combination of \((\rho_\varepsilon, \rho_x)\) is it worst?
Look at the residual series of one sample. Can you see the runs? Compare with the series of independent errors of the same dispersion.
Find a case where the conventional standard error is too large (hint: try a negative \(\rho_\varepsilon\) with positive \(\rho_x\)). Then switch to the persistent series (spurious) mode, where sales and advertising are two independent series, and raise the persistence: how often do you “discover” a relationship that does not exist?
What do we observe?#
The point estimate is unaffected. The histogram of \(\hat{\beta}_1\) stays centered on the true value, whatever the persistence of the errors. OLS remains unbiased.
But the distribution is wider than we think. When both the errors and the regressor are persistent, the estimates scatter much more than the conventional standard error suggests. The ratio between that standard error and the true dispersion falls below 1, and the 95% confidence intervals cover the true value noticeably less than 95% of the time. With \(\rho_\varepsilon = \rho_x = 0.6\) and \(T = 120\), for example, the conventional standard error is 0.69 times the true dispersion and the “95%” intervals cover about 82% of the time.
The damage requires persistence on both sides. If the regressor is not persistent (\(\rho_x = 0\)) or the errors are not (\(\rho_\varepsilon = 0\)), the problem disappears. It is the product of the two persistences that determines how much inference is distorted. With negatively correlated errors and a persistent regressor, the conventional standard error becomes too large, not too small.
Persistent series generate spurious relationships. When two independent series are highly persistent, regressing one on the other produces “significant” rejections far more often than 5% of the time (about 80% of the time for random walks with \(T = 120\)), along with a high \(R^2\) and a low Durbin-Watson statistic. We come back to this in section 4.4.
4. Formal Results: What Is Preserved and What Breaks#
4.1 Unbiasedness is preserved#
The proof of OLS unbiasedness only uses \(E[\varepsilon_t \mid X] = 0\) (strict exogeneity); it does not need the errors to be independent of each other. Therefore,
even if the errors follow an AR(1). The proof is the same as for the heteroscedastic case and is in the appendix. This explains why the histogram in the simulation does not shift.
4.2 Conventional standard errors are wrong#
In simple regression, the correct variance of \(\hat{\beta}_1\) is
The conventional formula \(\sigma^2/SST_x\) keeps only the diagonal terms (\(t = s\)); that is, it assumes all cross-covariances are zero. When errors are serially correlated, the cross terms do not vanish, and their sum depends on how similar the regressors of neighboring periods are: if \(x_t\) and \(x_s\) are also correlated, the cross-covariances add up instead of canceling out.
In the particular case where both the error and the regressor follow AR(1) processes with persistences \(\rho_\varepsilon\) and \(\rho_x\), and for large \(T\), the true variance is approximately
The derivation is in the appendix. The factor \(\frac{1+\rho_\varepsilon\rho_x}{1-\rho_\varepsilon\rho_x}\) is what the conventional formula ignores. With \(\rho_\varepsilon = \rho_x = 0.6\) it equals 2.1: the true variance is more than double the reported one, and the true standard error is 46% larger. With \(\rho_\varepsilon = 0.9\) and \(\rho_x = 0.6\), the values of the example we opened the section with, the factor is 3.3 and the true standard error is 1.8 times the conventional one, close to the ratio \(0.178/0.094 \approx 1.9\) in the opening table.
This can be read as a loss of information. We define the effective sample size as the number of independent observations that would give the same precision:
With 104 weeks and \(\rho_\varepsilon = 0.9\), \(\rho_x = 0.6\), we get \(T_{\text{eff}} \approx 31\): two years of data are worth, for this regression, about a month and a half of independent observations. The dashboard shows this same number computed by simulation.
Sign of the distortion. If \(\rho_\varepsilon\rho_x > 0\) (the usual case in economics and business, where errors and regressors tend to be persistent in the same direction), the conventional standard error understates uncertainty: intervals are too narrow and tests reject too often. If \(\rho_\varepsilon\rho_x < 0\), the opposite occurs. If either persistence is zero, the conventional formula is (approximately) correct.
4.3 Efficiency is lost#
The Gauss-Markov Theorem requires uncorrelated errors. With serial correlation, OLS remains linear and unbiased, but it is no longer the minimum-variance linear unbiased estimator. The intuition is direct: if the errors of neighboring weeks resemble each other, yesterday’s residual contains information about today’s error, and OLS wastes it. An estimator that exploits it (Generalized Least Squares, GLS) is more efficient. We will see it in section 6.
4.4 Persistent series and spurious regression#
The extreme version of the problem appears when series are so persistent that they behave like random walks (the case \(\phi = 1\) in the dashboard). Two independent series of this kind, regressed on each other, produce “significant” coefficients with a frequency that increases with sample size (78% at \(T = 120\) and 84% at \(T = 240\) in the dashboard), along with a high \(R^2\) and a Durbin-Watson near zero. This phenomenon was documented by Granger and Newbold [1974]. In that case the series are not stationary, and the correct treatment (differencing the series, or analyzing their cointegration) is beyond the scope of this book; the lesson that matters here is the warning: a high \(R^2\) with a very low Durbin-Watson is not good news, it is an alarm signal.
5. Diagnosing Serial Correlation#
Before defining the tests, the following dashboard lets you see what the different diagnostics “look like.” It generates data under five scenarios: no problem, AR(1) errors, MA(1) errors, omitted seasonality, and omitted trend. Explore these questions:
For each scenario, look at the residuals over time, the scatter plot of \(e_t\) against \(e_{t-1}\), and the autocorrelation function. Which ones “light up”?
Compare AR(1) errors with omitted seasonality (independent errors, but the model omits a seasonal term). Can you tell them apart by eye? And with the autocorrelation function?
Look at the Durbin-Watson statistic and compare it with \(2(1-\hat{\rho})\). What relationship do you observe?
In the power plot, how often does each test detect the problem when \(\rho\) is small? And when \(T\) is small?
5.1 Residual plots#
The first diagnostic is to look, and it is what the first three panels of the dashboard show. The plot of residuals over time shows runs of the same sign. The scatter plot of \(e_t\) against \(e_{t-1}\) should show a shapeless cloud if there is no serial correlation; a positive (negative) slope indicates positive (negative) correlation, and the slope is an estimate of \(\rho\). The autocorrelation function (ACF) of the residuals plots the correlation between \(e_t\) and \(e_{t-s}\) for \(s = 1, 2, \dots\), with approximate confidence bands of \(\pm 1.96/\sqrt{T}\): for an AR(1) it decays gradually; for an MA(1) it cuts off after the first lag; for omitted seasonality, periodic spikes appear.
5.2 Formal tests#
There are two classic tests. Both have no serial correlation as the null hypothesis.
Durbin-Watson [Durbin and Watson, 1950]. The statistic compares each residual with the previous one:
where \(\hat{\rho}_1\) is the sample first-order autocorrelation of the residuals (see the appendix). A value near 2 indicates no first-order correlation; values below 2 indicate positive correlation and values above 2, negative. It is simple to compute but has limitations: it only detects first-order correlation, it requires strictly exogenous regressors (it is not valid if a lagged dependent variable is among the regressors), and its exact distribution depends on \(X\), which gives rise to an “inconclusive” region in the classic tables. (The dashboard avoids this by using the asymptotic approximation \(DW \approx N(2, 4/T)\), which rejects when \(|DW - 2| > 1.96 \cdot 2/\sqrt{T}\).)
Breusch-Godfrey [Breusch, 1978, Godfrey, 1978]. This is a more general Lagrange multiplier test. The residuals \(e_t\) from the original regression are obtained, and then an auxiliary regression of \(e_t\) is run on the original regressors and on \(p\) lags of the residuals themselves, \(e_{t-1}, \dots, e_{t-p}\). The statistic
tests the joint hypothesis that the coefficients of the \(p\) lags are zero. It is valid with higher-order correlation and also when the model includes lagged dependent variables. The number of lags is chosen according to the data frequency: for example, 4 for quarterly data, 12 for monthly data, or the period of the expected seasonality.
Test |
Alternative hypothesis |
Requires strictly exogenous \(x\) |
Valid with \(y_{t-1}\) as a regressor |
|---|---|---|---|
Durbin-Watson |
First-order correlation |
Yes |
No |
Breusch-Godfrey |
Correlation up to order \(p\) |
No |
Yes |
What the dashboard shows about power. Under no problem, both tests reject about 5% of the time, as they should. Against a mild AR(1) (\(\rho = 0.3\), \(T = 120\)), Durbin-Watson detects it about 88% of the time, and Breusch-Godfrey 86% with one lag but only 52% with eight: adding lags dilutes the power against a first-order alternative. The reverse happens with the omitted seasonality (13-week period): Breusch-Godfrey with four lags detects it 56% of the time, and with eight lags 88%. The number of lags should reflect the alternative you want to be able to detect.
Other tests exist (for example, the Ljung-Box test applied to the residual series); in practice, Breusch-Godfrey is the safest choice because of its generality.
Part 1 of the notebook runs these diagnostics on real data (monthly atmospheric CO₂ at Mauna Loa): residual plots, ACF, Durbin-Watson and Breusch-Godfrey, and shows how adding month dummies removes the seasonal wave but not the persistence.
5.3 Serial correlation as a symptom#
Before reaching for robust errors, it is worth asking why there is serial correlation. Look at the dashboard again: omitted seasonality or an omitted trend generate residuals that look the same as a true AR(1), even though the underlying errors are independent. In that case, the solution is not statistical but one of specification: including the missing variable (seasonal dummies, a trend, a known event such as a product launch) often fixes the problem at its root, and is preferable to “patching” the standard errors. This connects with what we saw in the section on omitted variable bias: an incomplete specification can show up as a pattern in the residuals. Only when serial correlation persists after specifying the model properly do we need one of the tools in the next section.
6. The Fix: Robust Inference and Dynamic Models#
There are three responses, in increasing order of ambition: (i) keep OLS but correct the standard errors (HAC); (ii) model the error structure to gain efficiency (feasible GLS, Cochrane-Orcutt); (iii) model the dynamics by including lags. Before seeing the formulas, the following dashboard compares estimators. In static mode, explore:
Which estimators keep the right center of the distribution of \(\hat{\beta}_1\)? Which have “honest” standard errors (close to the true dispersion)? Which is the most precise?
Try small \(T\) with high \(\rho_\varepsilon\): what happens to the coverage of each estimator?
Change the Newey-West bandwidth. What happens if it is too short or too long?
6.1 HAC (Newey-West) Standard Errors#
The idea is the same as in the heteroscedasticity case: keep the OLS point estimates and replace the variance estimator with one that does not impose independence. The HAC (heteroscedasticity and autocorrelation consistent) standard errors of Newey and West [1987] estimate the sandwich matrix by including, besides the diagonal terms, the autocovariances of the residuals up to a lag \(L\):
where \(\hat{\Gamma}_\ell = \sum_{t=\ell+1}^{T} e_t\,e_{t-\ell}\,\mathbf{x}_t\mathbf{x}_{t-\ell}'\). The declining weights \((1 - \ell/(L+1))\) (the Bartlett kernel) guarantee that the estimated matrix is positive semidefinite. With \(L = 0\) no autocovariance is included and we get exactly White’s estimator (HC0) from the section on heteroscedasticity: HAC is the natural generalization of HC.
Choosing the bandwidth \(L\). An \(L\) that is too short ignores relevant autocovariances; one that is too long makes the estimator noisy. A common rule is \(L = \lfloor 4\,(T/100)^{2/9} \rfloor\) (3 for \(T = 60\), 4 for \(T = 240\)). In the dashboard, with \(\rho_\varepsilon = 0.9\) and \(T = 240\), \(L = 1\) gives a coverage of 79% against 87% for the automatic rule and 89% for \(L = 8\); with \(T = 30\), on the other hand, the long bandwidth is the worst of the four.
Limits. HAC is an asymptotic result: in small samples with high persistence, the standard errors still fall short and coverage stays below 95%: with \(\rho_\varepsilon = 0.9\) and \(\rho_x = 0.6\), the Newey-West interval covers 76% of the time with \(T = 30\) (the same as the conventional one), 82% with \(T = 60\), and 87% with \(T = 240\). It also does not correct OLS’s inefficiency. In practice, HAC plays in time series the role that HC1 plays in cross-sections: it is reported by default. In statsmodels: model.fit(cov_type='HAC', cov_kwds={'maxlags': L}).
💻 How to Estimate in Code
Part 2 of the same notebook from the previous section (Part 1, above) compares conventional and Newey-West standard errors for several bandwidths on the CO₂ series, and runs a small coverage simulation with the section’s weekly-sales DGP.
6.2 A bridge: clustered errors#
Correlation between errors need not be temporal. If, in an experiment, observations in the same group (users in the same city, products in the same category) share a component of the error, the effective information is closer to the number of groups than to the number of rows. Cluster-robust standard errors are the same idea as HAC, with a grouping structure instead of a time ordering: they allow arbitrary correlation within each group and assume zero correlation across groups. Their full treatment (the Moulton problem, choosing the clustering level, what to do with few groups) belongs to the section on panel data.
6.3 Feasible GLS: Cochrane-Orcutt#
If we believe the errors follow an AR(1), we can exploit that structure. Subtracting \(\rho\) times the equation at \(t-1\) from the equation at \(t\) (“quasi-differencing”) gives a model with independent errors:
Since \(\rho\) is unknown, the procedure of Cochrane and Orcutt [1949] estimates it from the OLS residuals, transforms the data, re-estimates, and iterates until \(\hat{\rho}\) converges (the Prais-Winsten variant keeps the first observation by rescaling it by \(\sqrt{1-\rho^2}\)). The result is a feasible GLS estimator, more efficient than OLS when the AR(1) model is correct, as seen in the dashboard: the histogram of \(\hat{\beta}_1\) is much narrower (with \(\rho_\varepsilon = 0.9\), \(\rho_x = 0.6\), and \(T = 60\), the standard deviation of the estimate is 0.07 against 0.20 for OLS), and its standard error is honest.
But there are costs. The efficiency gain depends on the AR(1) structure being correct and on the regressors being strictly exogenous: the good coverage you see in the dashboard exists because the simulated errors are AR(1), a luxury real data do not offer. With little data, estimating \(\hat{\rho}\) also adds noise, and the iteration occasionally fails to converge (the dashboard counts these cases and excludes them). A reasonable practice is to use GLS as a robustness check or when efficiency matters, and always report the HAC errors.
💻 How to Estimate in Code
Part 3 of the notebook applies GLSAR (iterated Cochrane-Orcutt) to the CO₂ series, compares it with OLS plus Newey-West, and re-checks Breusch-Godfrey on the transformed residuals.
6.4 Modeling the dynamics: lags and the care needed with \(y_{t-1}\)#
Imposing AR(1) errors amounts to assuming a very particular relationship among the coefficients of a model with lags. Indeed, from \(y_t = \beta_0 + \beta_1 x_t + \varepsilon_t\) and \(\varepsilon_t = \rho\varepsilon_{t-1} + u_t\) we get
a model with \(y_{t-1}\) and \(x_{t-1}\) whose coefficients are restricted to each other. This motivates an alternative: instead of imposing the restriction, include lags freely (\(y_{t-1}\), \(x_{t-1}\), and as many as needed) until the residuals show no serial correlation, which is checked with Breusch-Godfrey. Such a model is dynamically complete.
But this path hides a danger. Suppose the true model already has a lagged dependent variable, \(y_t = \beta_0 + \gamma\,y_{t-1} + \beta_1 x_t + \varepsilon_t\) (the effect of advertising builds up over time), and the errors are serially correlated. When \(y_{t-1}\) enters as a regressor and the errors remain serially correlated, the regressor stops being exogenous: \(y_{t-1}\) depends on \(\varepsilon_{t-1}\), which in turn is correlated with \(\varepsilon_t\). Then \(\text{Cov}(y_{t-1}, \varepsilon_t) \neq 0\) and OLS is inconsistent: not only are the standard errors wrong, the estimator itself converges to the wrong value, and does not improve as \(T\) grows. HAC errors do not repair it: they correct the uncertainty around the wrong center. Explore this problem in the dashboard, now in the lagged-\(y\) mode (with \(\gamma = 0.5\)), with these questions:
What happens to the estimate of the coefficient on \(y_{t-1}\) as you raise \(T\) and \(\rho_\varepsilon\)? Does it approach the true value?
Do Newey-West errors help?
What does the specification with additional lags (\(y_{t-2}\) and \(x_{t-1}\)) do?
The dashboard confirms the diagnosis: with \(\rho_\varepsilon = 0.9\) and \(T = 240\), OLS with \(y_{t-1}\) estimates the effect of advertising at 1.25 on average (true value 1.5) and the coefficient on \(y_{t-1}\) at 0.70 (true value 0.5), and the 95% intervals, with conventional or Newey-West errors, cover the truth only 5% and 9% of the time. With more data the estimate does not improve; it only concentrates around the wrong value.
The solution is to specify the dynamics correctly. If the errors are AR(1), substituting \(\varepsilon_t = \rho\,\varepsilon_{t-1} + u_t\) shows that the model is equivalent to
with independent errors \(u_t\). Estimating that specification by OLS (the ADL(2,1) of the dashboard) is consistent for the effect of \(x_t\): in the same cell, it averages 1.50 with 95% coverage. Note that the coefficient on \(y_{t-1}\) in this regression estimates \(\gamma+\rho\), not \(\gamma\); recovering the structural parameters would require imposing the restrictions among the coefficients. Another way out is to use instrumental variables, the topic of the sections on Instrumental Variables. ARMA and ARIMA models, forecasting, and unit roots belong in a time-series course; the tools in this section are enough to recognize the problem and obtain valid inference in a regression.
💻 How to Estimate in Code
Part 4 of the notebook reproduces the lagged-\(y\) dashboard on a frozen simulated draw: OLS with \(y_{t-1}\) (conventional and Newey-West), the ADL(2,1), and a 300-replication loop showing that the bias of \(\hat{\gamma}\) does not shrink with \(T\).
7. Summary and Decision Guide#
Serial correlation does not invalidate OLS regression under strict exogeneity, but it compromises inference and efficiency. The following path summarizes recommended practice:
Always plot the residuals over time and their autocorrelation function.
Run Breusch-Godfrey to confirm statistically (Durbin-Watson as a quick complement).
First ask whether something is missing from the model: seasonality, a trend, a known event. Including it is often better than correcting standard errors.
If serial correlation persists: use HAC (Newey-West) standard errors by default. This is the minimum practice in time series.
If efficiency matters: consider feasible GLS or a model with lags, checking with Breusch-Godfrey that the residuals end up uncorrelated, and always report OLS+HAC as a robustness check.
If \(y_{t-1}\) is a regressor: the problem is consistency, not standard errors. Specify the dynamics properly or use instruments.
If the correlation is by group (users in the same city, etc.), use clustered errors (panel section).
Under strict exogeneity, OLS point estimates are not discarded: only the quantification of uncertainty changes. And the same idea, nearby observations that resemble each other and effective information smaller than \(N\), reappears in the next section, with geographic distance in place of time.
Appendix: Formal Derivations#
A.1 OLS Unbiasedness Does Not Require Independent Errors#
We want to show that \(E[\hat{\beta}_1 \mid X] = \beta_1\) with serially correlated errors.
Step 1 — As in the previous section, substituting \(y_t = \beta_0 + \beta_1 x_t + \varepsilon_t\) into the OLS formula:
Step 2 — Take the conditional expectation given \(X\):
Step 3 — Under strict exogeneity, \(E[\varepsilon_t \mid X] = 0\) for all \(t\), and the second term vanishes. No step used \(\text{Cov}(\varepsilon_t, \varepsilon_s) = 0\): unbiasedness holds even if the errors are correlated with each other.
A.2 Variance of \(\hat{\beta}_1\) with AR(1) Errors and an AR(1) Regressor#
Step 1 — From A.1, \(\hat{\beta}_1 - \beta_1 = \sum_t (x_t - \bar{x})\varepsilon_t / SST_x\). Conditioning on \(X\):
Step 2 — With stationary AR(1) errors, \(\text{Cov}(\varepsilon_t, \varepsilon_s) = \sigma^2\rho_\varepsilon^{|t-s|}\) with \(\sigma^2 = \text{Var}(\varepsilon_t)\). Grouping the pairs \((t,s)\) by distance \(k = |t-s|\):
where \(\hat{r}_k\) is the sample autocorrelation of order \(k\) of the regressor.
Step 3 — If the regressor is AR(1) with persistence \(\rho_x\), for large \(T\), \(\hat{r}_k \to \rho_x^{\,k}\). Substituting and summing the geometric series:
Therefore \(\text{Var}(\hat{\beta}_1 \mid X) \approx \frac{\sigma^2}{SST_x}\cdot\frac{1+\rho_\varepsilon\rho_x}{1-\rho_\varepsilon\rho_x}\). Since the conventional formula estimates only \(\sigma^2/SST_x\), the ratio between the true and the conventional variance is precisely \(\frac{1+\rho_\varepsilon\rho_x}{1-\rho_\varepsilon\rho_x}\), and the effective sample size is \(T_{\text{eff}} \approx T\,\frac{1-\rho_\varepsilon\rho_x}{1+\rho_\varepsilon\rho_x}\).
A.3 The Durbin-Watson Statistic and the Residual Autocorrelation#
Step 1 — Expanding the square in the numerator:
Step 2 — For large \(T\), the first two sums are approximately equal to \(\sum_{t=1}^{T}e_t^2\) (they differ only by an endpoint term). Dividing by \(\sum_t e_t^2\):
where \(\hat{\rho}_1\) is the sample first-order autocorrelation of the residuals. If \(\hat{\rho}_1 = 0\), \(DW \approx 2\); if \(\hat{\rho}_1 \to 1\), \(DW \to 0\); if \(\hat{\rho}_1 \to -1\), \(DW \to 4\).
Test what you learned#
References#
Trevor S Breusch. Testing for autocorrelation in dynamic linear models. Australian Economic Papers, 17(31):334–355, 1978.
Donald Cochrane and Guy H Orcutt. Application of least squares regression to relationships containing auto-correlated error terms. Journal of the American Statistical Association, 44(245):32–61, 1949.
James Durbin and Geoffrey S Watson. Testing for serial correlation in least squares regression: i. Biometrika, 37(3/4):409–428, 1950.
Leslie G Godfrey. Testing against general autoregressive and moving average error models when the regressors include lagged dependent variables. Econometrica, 46(6):1293–1301, 1978.
Clive WJ Granger and Paul Newbold. Spurious regressions in econometrics. Journal of Econometrics, 2(2):111–120, 1974.
Whitney K Newey and Kenneth D West. A simple, positive semi-definite, heteroskedasticity and autocorrelation consistent covariance matrix. Econometrica, 55(3):703–708, 1987.