HAC regression - manually specify lags

For technical questions regarding estimation of single equations, systems, VARs, Factor analysis and State Space Models in EViews. General econometric questions and advice should go in the Econometric Discussions forum.

Moderators: EViews Gareth, EViews Moderator

cap
Posts: 55
Joined: Fri Oct 17, 2008 11:47 am

HAC regression - manually specify lags

Postby cap » Fri Jul 24, 2009 2:09 pm

Hello,

When doing a HAC regression (newey west standard errors), I see in the documentation that the lag truncation is automatically determined according to some formula ... is it possible to instead manually specify this ourselves?

Thanks
-cap

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13600
Joined: Tue Sep 16, 2008 5:38 pm

Re: HAC regression - manually specify lags

Postby EViews Gareth » Fri Jul 24, 2009 2:50 pm

Short Answer: No.

Longer Answer: You could estimate your equation as a GMM estimation, using inputting your regressors as instruments (although this only works if you have a constant in your regressors, since EViews always adds a constant to the instrument list). This will let you specify the lag truncation for Newey-West.

The one problem with the GMM solution is that the degree-of-freedom correction for the standard errors is different from a Least-Squares regression. You'd have to multiply your standard-errors by sqrt(T/(T-k)) to get them to match.

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13600
Joined: Tue Sep 16, 2008 5:38 pm

Re: HAC regression - manually specify lags

Postby EViews Gareth » Fri Jul 24, 2009 3:05 pm

Just a quick program to prove that you can replicate LS Newey-West by estimating an equation by GMM:

Code: Select all

rndseed 1 !t=100 !k=3 create u !t series y=nrnd series x1=nrnd series x2=nrnd equation e1.ls(n) y c x1 x2 equation e2.gmm(b=4) y c x1 x2 @ x1 x2 vector ses = e2.@stderrs ses = ses * @sqrt(!t/(!t-!k)) show e1 show ses
Then, if you want to use a different lag truncation, you could change the "b=4" option to "b=" whatever number you want.

cap
Posts: 55
Joined: Fri Oct 17, 2008 11:47 am

Re: HAC regression - manually specify lags

Postby cap » Fri Jul 24, 2009 3:48 pm

Thanks very much for your help!


Return to “Estimation”

Who is online

Users browsing this forum: No registered users and 2 guests