Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: st: newey v.s. ivregress 2sls, vce(hac nw)


From   "Narita, Futoshi" <[email protected]>
To   "[email protected]" <[email protected]>
Subject   RE: st: newey v.s. ivregress 2sls, vce(hac nw)
Date   Tue, 11 Sep 2012 17:21:24 -0400

Dear Brian Poi, 

Thank you so much for your quick and clear answer!

I've confirmed that I get the same results as you suggested. I'm very happy to understand it. 

Thank you very much! 
Futoshi



-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Brian P. Poi
Sent: Tuesday, September 11, 2012 4:58 PM
To: [email protected]
Subject: Re: st: newey v.s. ivregress 2sls, vce(hac nw)

On 09/11/2012 03:02 PM, Narita, Futoshi wrote:
> Dear statalisters,
>
> I have greatly benefitted from the following very useful thread:
>
> http://www.stata.com/statalist/archive/2009-03/msg01009.html
>
> But, I have come up with one question as follows:
>
> Why do we get different standard errors when we use "newey, lag(xx)" and " ivregress 2sls, vce(hac nw xx)"?
>
> The above-mentioned thread seems to claim that "ivregress 2sls" is used to calculate HAC standard errors and if we choose "nw" option, it should calculate the same standard errors as "newey" does. But, the results are different.
>
> Please run the following example (based on the one in the cited thread) to see the discrepancies:
>
> // Begin example
>
> clear
> freduse GDPC96 PCECC96
> gen t = qofd(daten)
> format t %tq
> drop date*
> tsset t
>
> gen y = ln(GDPC96)
> gen c = ln(PCECC96)
>
> ivreg2 c y L(-4/4)D.y, bw(14) robust
> ivregress 2sls c y L(-4/4)D.y, vce(hac nw 13)
> newey c y L(-4/4)D.y, lag(13)
>
> // End example
>
> The first two estimation results are identical, but the last one is slightly different from others. I set ivreg2's "bandwidth" to be correctly corresponding to "lag"s (i.e., bw = lag + 1).
>
> I have my own Mata code that calculates Newey-West standard errors, based on the formula in Hayashi (2000). My code gives me exactly the same results as "newey" does. So, then, do "ivregress" and "ivreg2" use a different formula? I tried to replace the denominator ("n" versus "n-j") but didn't get it matched (though my code may have errors).
>
> I would really appreciate it if anybody could tell me the reason of the discrepancies and/or could help solve my possible misunderstanding.
>

Futoshi,

The difference really is just a degree-of-freedom adjustment.  By default, -ivreg2- and -ivregress- report large-sample statistics that do not adjust for degrees of freedom, while -newey- reports small-sample statistics that do adjust.  -ivreg2- and -ivregress- both accept a 'small' option to get small-sample statistics, and when you use that option, you get the same results as -newey-:

. ivreg2 c y L(-4/4)D.y, bw(14) robust small
. ivregress 2sls c y L(-4/4)D.y, vce(hac nw 13) small
. newey c y L(-4/4)D.y, lag(13)

produce identical standard errors.

    -- Brian Poi
    -- [email protected]




*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index