Page 1 of 1
HAC corrected variance in unit root tests
Posted: Fri Nov 23, 2012 1:24 am
by kiber_master
Hello!
In your documentation I found that HAC corrected variance in PP, ERS unit root tests is calculated using Dickey-Fuller regression, so it should be the same in both tests for series with identical values and the same sample. But when I calculate this tests and set sample not from 1st point, EViews gives me different HAC corrected variance in PP and ERS for Kernel spectral estimation methods. Why? Is it a mistake in documentation, or in calculation?
Thank you.
P.S.: Tell me, if you need an example
Re: HAC corrected variance in unit root tests
Posted: Mon Nov 26, 2012 10:30 am
by EViews Glenn
We're going to need an example. I'm not quite certain what you are saying here...
Re: HAC corrected variance in unit root tests
Posted: Tue Nov 27, 2012 8:09 am
by kiber_master
In attached workfile execute the following code
smpl 2005m02 2012m04
freeze(t1) y.uroot(ers, none)
freeze(t2) y.uroot(pp, none)
HAC in t1 differs from t2, though they are calculated by the same formula.
Re: HAC corrected variance in unit root tests
Posted: Tue Nov 27, 2012 11:17 am
by EViews Glenn
Before I delve too much into this, you are aware, aren't you, that the PP and ERS use different residuals...
Re: HAC corrected variance in unit root tests
Posted: Tue Nov 27, 2012 11:02 pm
by kiber_master
I don't understand you. In documentation it is said that residuals for both tests are the same!
See EViews 7 Users Guide II, Chapter 13. Univariate Time Series Analysis, table at p.389:
PP, ERS Point Optimal, NP - residuals from the Dickey-Fuller test equation.
Re: HAC corrected variance in unit root tests
Posted: Wed Nov 28, 2012 5:32 pm
by EViews Glenn
The table isn't correct. The text is. The ERS Point Optimal and NP tests are as described in the previous pages. I'll make a note to have someone clean this up.
Re: HAC corrected variance in unit root tests
Posted: Thu Nov 29, 2012 1:05 am
by kiber_master
It isn't evident for me, residuals from which model should be used to calculate HAC corrected variance. Could you tell me?
Re: HAC corrected variance in unit root tests
Posted: Thu Nov 29, 2012 10:50 am
by EViews Glenn
Sorry, I hadn't meant to post that last one. Ignore it. They were some initial thoughts before thinking too hard about the issue and I meant to delete it before posting.
My original comment about the residuals was because I was thinking about the residuals from the DFGLS which are indeed different from those from the DF. But obviously that wasn't your question.
By the way, your original code example doesn't work since ERS doesn't support NONE. Once you let me know which specific test to look at I can look into this more closely. Sorry again for the confusion.
Re: HAC corrected variance in unit root tests
Posted: Fri Nov 30, 2012 7:24 am
by kiber_master
Sorry for wrong code. The correct code is following
smpl 2005m02 2012m04
freeze(t2) y.uroot(pp, const)
freeze(t1) y.uroot(ers, const, hac=bt)
Re: HAC corrected variance in unit root tests
Posted: Fri Nov 30, 2012 4:13 pm
by EViews Glenn
It's the same presample issue as in the Phillips-Perron test (
http://forums.eviews.com/viewtopic.php?f=4&t=7089). You'll see this if you set your sample to start at the first observation in the workfile.
I'm inclined to line up all of the presample handling, but to do so in EViews 8. It's not a bug in the calculation, be we can and do strive for consistency in approaches as much as possible, and I think it best to correct this, but would rather not do it mid-release.
Thanks for your help.
Re: HAC corrected variance in unit root tests
Posted: Sun Dec 02, 2012 11:46 pm
by kiber_master
Thank you.