LECTURE 11 Introduction to Econometrics Autocorrelation November 29, 2016 1 / 24 ON PREVIOUS LECTURES We discussed the specification of a regression equation Specification consists of choosing: 1. correct independent variables 2. correct functional form 3. correct form of the stochastic error term We talked about the choice of independent variables and their functional form We started to talk about the form of the error term - we discussed heteroskedasticity 2 / 24 ON TODAY’S LECTURE We will finish the discussion of the form of the error term by talking about autocorrelation (or serial correlation) We will learn what is the nature of the problem what are its consequences how it is diagnosed what are the remedies available 3 / 24 NATURE OF AUTOCORRELATION Observations of the error term are correlated with each other Cov(εi, εj) = 0 , i = j Violation of one of the classical assumptions Can exist in any data in which the order of the observations has some meaning - most frequently in time-series data Particular form of autocorrelation - AR(p) process: εt = ρ1εt−1 + ρ2εt−2 + . . . + ρpεt−p + ut ut is a classical (not autocorrelated) error term ρk are autocorrelation coefficients (between -1 and 1) 4 / 24 EXAMPLES OF PURE AUTOCORRELATION Distribution of the error term has autocorrelation nature First order autocorrelation εt = ρ1εt−1 + ut positive serial correlation: ρ1 is positive negative serial correlation: ρ1 is negative no serial correlation: ρ1 is zero positive autocorrelation very common in time series data e.g.: a shock to GDP persists for more than one period Seasonal autocorrelation (in quarterly data) εt = ρ4εt−4 + ut 5 / 24 EXAMPLES OF IMPURE AUTOCORRELATION Autocorrelation caused by specification error in the equation: omitted variable incorrect functional form How can misspecification cause autocorrelation in the error term? Recall that the error term includes the omitted variables, nonlinearities, measurement error, and the classical error term. If we omit a serially correlated variable, it is included in the error term, causing the autocorrelation problem. Impure autocorrelation can be corrected by better choice of specification (as opposed to pure autocorrelation). 6 / 24 AUTOCORRELATION X Y 7 / 24 CONSEQUENCES OF AUTOCORRELATION 1. Estimated coefficients (β) remain unbiased and consistent 2. Standard errors of coefficients (s.e.(β)) are biased (inference is incorrect) serially correlated error term causes the dependent variable to fluctuate in a way that the OLS estimation procedure attributes to the independent variable Serial correlation typically makes OLS underestimate the standard errors of coefficients therefore we find t scores that are incorrectly too high ⇒ The same consequences as for the heteroskedasticity 8 / 24 DURBIN-WATSON TEST FOR AUTOCORRELATION Used to determine if there is a first-order serial correlation by examining the residuals of the equation Assumptions (criteria for using this test): The regression includes the intercept If autocorrelation is present, it is of AR(1) type: εt = ρεt−1 + ut The regression does not include a lagged dependent variable 9 / 24 DURBIN-WATSON TEST FOR AUTOCORRELATION Durbin-Watson d statistic (for T observations): d = T t=2 (et − et−1)2 T t=1 e2 t ≈ 2(1 − ρ) where ρ is the autocorrelation coefficient Values: 1. Extreme positive serial correlation: d ≈ 0 2. Extreme negative serial correlation: d ≈ 4 3. No serial correlation: d ≈ 2 10 / 24 USING THE DURBIN-WATSON TEST 1. Estimate the equation by OLS, save the residuals 2. Calculate the d statistic 3. Determine the sample size T and the number of explanatory variables (excluding the intercept!) k 4. Find the upper critical value dU and the lower critical value dL for T and k in statistical tables 5. Evaluate the test as one-sided or two-sided (see next slides) 11 / 24 ONE-SIDED DURBIN-WATSON TEST For cases when we consider only positive serial correlation as an option Hypothesis: H0 : ρ ≤ 0 (no positive serial correlation) HA : ρ > 0 (positive serial correlation) Decision rule: if d < dL reject H0 if d > dU do not reject H0 if dL ≤ d ≤ dU inconclusive 12 / 24 DURBIN-WATSON CRITICAL VALUES FOR ONE-SIDED TEST 13 / 24 TWO-SIDED DURBIN-WATSON TEST For cases when we consider both signs of serial correlation Hypothesis: H0 : ρ = 0 (no serial correlation) HA : ρ = 0 (serial correlation) Decision rule: if d < dL reject H0 if d > 4 − dL reject H0 if d > dU do not reject H0 if d < 4 − dU do not reject H0 otherwise inconclusive 14 / 24 DURBIN-WATSON CRITICAL VALUES FOR TWO-SIDED TEST 15 / 24 EXAMPLE Estimating housing prices in the UK Quarterly time series data on prices of a representative house in UK (in £) Explanatory variable: GDP (in billions of £) Time span: 1975 Q1 - 2011 Q2 All series are seasonally adjusted and in real prices (i.e. adjusted for inflation) 16 / 24 EXAMPLE 60000 80000 100000 120000 140000 160000 180000 200000 220000 1975 1980 1985 1990 1995 2000 2005 2010 Priceofrepresentativehouse 17 / 24 EXAMPLE               18 / 24 EXAMPLE We test for positive serial correlation: H0 : ρ ≤ 0 (no positive serial correlation) HA : ρ > 0 (positive serial correlation) One-sided DW critical values at 95% confidence for T = 146 and k = 1 are: dL = 1.72 and dU = 1.74 Decision rule: if d < 1.72 reject H0 if d > 1.74 do not reject H0 if 1.72 ≤ d ≤ 1.74 inconclusive Since d = 0.02 < 1.72, we reject the null hypothesis of no positive serial correlation 19 / 24 ALTERNATIVE APPROACH TO AUTOCORRELATION TESTING Suppose we suspect the stochastic error term to be AR(p) εt = ρ1εt−1 + ρ2εt−2 + . . . + ρpεt−p + ut Since OLS is consistent even under autocorrelation, the residuals are consistent estimates of the stochastic error term Hence, it is sufficient to: 1. Estimate the original model by OLS, save the residuals et 2. Regress et = ρ1et−1 + ρ2et−2 + . . . + ρpet−p + ut 3. Test if ρ1 = ρ2 = . . . = ρp = 0 using the standard F-test 20 / 24 BACK TO EXAMPLE               21 / 24 BACK TO EXAMPLE                 22 / 24 REMEDY: WHITE ROBUST STANDARD ERRORS Note that autocorrelation does not lead to inconsistent estimates, only to incorrect inference - similar to heteroskedasticity problem We can keep the estimated coefficients, and only adjust the standard errors The White robust standard errors solve not only heteroskedasticity, but also serial correlation Note also that all derived results hold if the assumption Cov(x, ε) = 0 is not violated First make sure the specification of the model is correct, only then try to correct for the form of an error term! 23 / 24 SUMMARY Autocorrelation does not lead to inconsistent estimates, but it makes the inference wrong (estimated coefficients are correct, but their standard errors are not) It can be diagnosed using Durbin-Watson test Analysis of residuals It can be remedied by White robust standard errors Readings: Studenmund, Chapter 9 Wooldridge, Chapter 12 24 / 24