These noes largely concern auocorrelaion Issues Using OLS wih Time Series Daa Recall main poins from Chaper 10: Time series daa NOT randomly sampled in same way as cross secional each obs no i.i.d Why? Daa is a sochasic process we have one realizaion of he process from a se of all possible realizaions Leads o a Number of Common problems: 1. Errors correlaed over ime high errors oday high nex ime (biased sandard errors bu no biased coefficiens) 2. Effecs may ake a while o appear difficul o know how long should wai o see effecs (ax cus is growh in Clinon years due o Clinon? Reagan?) (specificaion problem) 3. Feedback effecs (x y bu afer seeing y, policy makers adjus x) (specificaion problem can lead o biased coeffs) 4. Trending daa over ime daa series can look like hey are relaed, bu really is spurious (biased coeffs) Relaed Issue: Predicion ofen wan a predicion of fuure prices, GDP, ec. Need o use properies of exising series o make ha predicion
Recall Chaper 10 Models These models deal wih problems 2 and 4 lised above 1. Saic model-- Change in z has an immediae effec in same period on y y = 0 + 1 z + u =1,2, n 2. Finie Disribued lag Model y = + 0 z + 1 z -1 + 2 z -2 + u Know number of lags =1,2, n 3. Trending Daa: Add a rend y = 0 + 1 + e, = 1,2 Or Derend he daa Noe ha if DO NOT correcly specify he model (e.g., wih lagged daa), can generae serial correlaion. Correc specificaion is he firs problem o address.
P&R 6.2 Serial Correlaion: Wha is serial correlaion and why is i a problem? Serial correlaion comes when errors from one ime period are carried over ino fuure ime periods (problem # 1 lised above) Can also occur spaially errors in his area are correlaed wih errors in adjacen area Mos auhors use serial and auo-correlaion inerchangeably. Some use auo corr o refer o serial correlaion wihin a series isel and serial correlaion o refer o lagged correlaion beween wo ime series. I ll use hem inerchangeably. Posiive serial correlaion ofen caused by --Ineria some economic ime series have momenum (?) --Correlaion in omied variables over ime --Correlaion in measuremen error componen of error erm --Theoreical predicions--adapive expecaions, some parial adjusmen process --Misspecificaion e.g., omied dynamic erms (lagged dependen or independen variables, rends) --Daa is already inerpolaed (e.g., daa beween Census years) --Non-saionariy will discuss laer
Example: AR(1) Process Very common form of serial correlaion Firs Order Auoregressive process: AR(1) True model: y = β 0 +β 1 x 1 + β 2 x 2 +....β k X k + = -1 + v 0 1 [If had 2 lags, would be AR(2)] v is he idiosyncraic par of he error, Indep of oher errors over ime, N(0, 2 v) e is NOT indep of oher errors over ime, N(0, 2 ) error in ime is deermined by he diminishing value of error in previous period ( ) + addiion of random variable v, wih EV(0) Implies ha error in any period is refleced in all fuure periods Var( ) = E( 2 ) = E[( -1 + v ) 2 ] = E[ 2 2-1 + v 2 + 2-1 v ] = 2 E( 2-1) + E(v 2 ) b/c -1 and v are indep Var( ) = 2 Var( ) + 2 v if ( ) is homoskedasic Var( )= Var( -1 ) Algebra Var( )= 2 v /(1-2 ) Noe ha when =0, no auocorrel. How are he errors relaed over ime? Cov(, -1 ) = E(, -1 )= E[( -1 + v ) -1 ] = E( 2-1 + -1 v ) = E( 2-1) = Var( ) = 2 Similarly, Cov(, -2 )= 2 2, Cov(, -3 )= 3 2 Similarly, Cov(, -s )= s 2
Noe ha is he correlaion coefficien beween errors a ime and -1. Also known as coefficien of auocorrelaion a lag 1 Saionariy: Criical ha <1 oherwise hese variances and covariances are undefined. If <1, we say ha he series is saionary. If =1, nonsaionary. Chaper 11 in your book discusses concep of saionariy. For now, brief definiion. If mean, variance, and covariance of a series are ime invarian, series is saionary. Will discuss laer ess of saionariy and wha o do if daa series is no saionary. Serial correlaion leads o biased sandard errors If y is posiively serially correlaed and x is posiively serially correlaed, will undersae he errors Show figure 6.1 for why Noe ha 1 s case have posiive error iniially, second case have negaive error iniially Boh cases equally likely o occur unbiased Bu OLS line fis he daa poins beer han rue line Wih algebra: Usual OLS Esimaor y = β 0 +β 1 x 1 + ( )
Wih AR(1) ( ) [ ] How does his compare wih sandard errors in OLS case? Depends on sign of p and ype of auocorrelaion in xs If x is posiively correlaed over ime and p is posiive, OLS will undersae rue errors T, F sas all wrong R2 wrong See Gujarai for a Mone Carlo experimen on how large hese misakes can be
Tess for Serial Correlaion 1. Graphical mehod Graph (residuals) errors in he equaion---very commonly done. Can also plo residuals agains lagged residuals see Gujarai fig 12.9 2. Durbin Wason Tes Oldes es for serial correlaion P&R goes hrough exension when have lagged y s in model see 6.2.3 for deails Null hypohesis: No serial correlaion =0 Alernaive: 0 (wo ailed) >0 (one ailed) Tes saisic: Sep 1: Run OLS model y = β 0 +β 1 x 1 + β 2 x 2 +....β k X k + Sep 2: Calculae prediced residuals Sep 3: Form es saisic T 2 ( ˆ ˆ 1) 2 DW 2(1 ˆ) (See Gujarai pg 435 o derive) T 2 ( ˆ ) 1 Assumpions: 1. Regression includes inercep erm 2. Xs are fixed in repeaed sampling non-sochasic (problemaic in ime series conex) 3. Can only be used for 1 s order auoregression processes 4. Errors are normally disribued 5. No lagged dependen variables no applicable in hose models 6. No missing obs
This saisic ranges from 0 o 4 ˆ are close o each oher Posiive serial correlaion DW will be close o zero (below 2) No serial correlaion DW will be close o 2 Negaive serial correlaion DW will be large (above 2) Exac inerpreaion difficul because sequence of prediced error erms depends on x s as well if x s are serially correlaed, correlaion of prediced errors may be relaed o his and no serial correlaion of s 2 criical values d L and d U --see book for char STATA: esa dwsa
3. Breusch-Godfrey es This is ye anoher example of an LM es Null hypohesis: Errors are serially independen up o order p One X: Sep 1: Run OLS model y = β 0 +β 1 x 1 + (Regression run under he null) Sep 2: Sep 3: Sep 4: Calculae prediced residuals Run auxiliary regression ˆ 1 2X ˆ v T-es on ˆ 1 STATA: esa bgodfrey, lags(**) Muliple X, muliple lags Sep 1: Run OLS model y = β 0 +β 1 x 1 + β 2 x 2 +....β k X k + (Regression run under he null) Sep 2: Sep 3: Sep 4: Calculae prediced residuals Run auxiliary regression ˆ 1 2Xs ˆ ˆ... p ˆ 1 1 2 1 wih higher order lags Bruesch-Godfrey es (n-p)r 2 ~ χ 2 (p) p v BP es is more general han DW es cam include laggesd Ys, moving average models Do need o know p order or he lag. Will alk some abou his choice laer.
Correcing for Serial Correlaion 1. Check is i model misspecificaion? --rend variable? --quadraics? --lagged variables? 2. Use GLS esimaor see below 3. Use Newey Wes sandard errors like robus sandard errors GLS Esimaors: Correcion1: Known : Adjus OLS regression o ge efficien parameer esimaes Wan o ransform he model so ha errors are independen = -1 + v wan o ge rid of -1 par How? Linear model holds for all ime periods. y -1 = β 0 +β 1 x 1-1 + β 2 x 2-1 +....β k X k-1 + -1 1. Muliply above by 2. Subrac from base model: y* = β 0 (1- ) + β 1 x* 1 + β 2 x* 2 +....β k X* k + v Where y* = y - y -1, same for xs Noe ha his is like a firs difference, only are subracing par and no whole of y-1 Generalized differences Now error has a mean =0 and a consan variance Apply OLS o his ransformed model efficien esimaes This is he BLUE esimaor PROBLEM: don know
Correcion2: Don Know --Cochrane-Orcu Idea: sar wih a guess of and ierae o make beer and beer guesses Sep 1: Run ols on original model y = β 0 +β 1 x 1 + β 2 x 2 +....β k X k + Sep 2: Obain prediced residuals and run following regression ˆ ˆ v 1 Sep 3: Obain prediced value of. Transform daa using * generalized differencing ransformaion y y ˆ y 1, same for X* Sep 4: Rerun regression using ransformed daa y * ( 1 ˆ) x... x 0 1 * 1 Obain new esimaes of beas-- ˆ k * k v Sep 5: Form new esimaed residuals using newly esimaed beas and ORIGINAL daa (no ransformed daa) y ( ˆ ˆ x... ˆ x ˆ 0 1 1 Ierae unil new esimaes of are close o old esimaes (differ by.01 or.005) k k Correcion3: Don Know --Hildreh-Lu (less popular) Numerical minimizaion mehod Minimize sum of squared residuals for various guesses of for y* = β 0 (1- ) + β 1 x* 1 + β 2 x* 2 +....β k X* k + v Choose range of poenial (e.g., 0,.1,.2,.3,...., 1.0), idenify bes one (e.g.,.3), pick oher numbers close by (e.g.,.25,.26,...,.35), ierae
Correcion 4: Firs difference Model lies beween 0 and 1. Could run a firs differenced model as he oher exreme. This is he appropriae correcion when series is non-saionary alk abou nex ime. Recall: Correcing for Serial Correlaion 1. Check is i model misspecificaion? --rend variable? --quadraics? --lagged variables? 2. Use GLS esimaor see below 3. Use Newey Wes sandard errors like robus sandard errors Newey Wes sandard errors Exension of Whie sandard errors for heeroskedasiciy Only valid in large samples Final Noes: Should you use OLS or FGLS or Newey-Wes errors? OLS: --unbiased --consisen --asympoically normal --,F, r2 no appropriae FGLS/Newey Wes --efficien --small sample properies no well documened no unbiased --in small samples, hen, migh be worse
--Griliches and Rao rule of humb is sample is small (<20, iffy 20-50) and <.3, OLS beer han FGLS