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

st: re: overid error

From   Kit Baum <>
Subject   st: re: overid error
Date   Tue, 24 Nov 2009 07:18:19 -0500

John points out that the old overid code for reg3 produced the same overid stat if 3SLS was being performed. That is still true with the new overid code:

use, clear
xi i.year
qui ivreg2 lw s expr tenure rns smsa _I* (iq=med kww age mrt)
predict double eps31, res equation(lw)
predict double eps32, res equation(iq)

qui reg3 (lw =iq s expr tenure rns smsa _I*) (iq=med kww age mrt s expr ///
tenure rns smsa _Iyear_67 _Iyear_68 _Iyear_69 _Iyear_70 _Iyear_71 _Iyear_73)
predict double eps21, res equation(lw)
predict double eps22, res equation(iq)

He wonders why the same result is not obtained if the 2sls option is invoked in reg3:

qui reg3 (lw =iq s expr tenure rns smsa _I*) (iq=med kww age mrt s expr ///
tenure rns smsa _Iyear_67 _Iyear_68 _Iyear_69 _Iyear_70 _Iyear_71 _Iyear_73), 2sls

and it is not. Obviously the logic of overid is the same  (I am using the current version of overid, incorporating more efficient code), so the issue is what is changing in the information passed along to overid by reg3.  The most important information involves the residuals. I have included statements to save those above. Now let's see if they differ:

g double dif1 = eps31 - eps21
g double dif2 = eps32 - eps22
su eps* dif*

examination of the output reveals that the residuals from the first equation are identical to near machine precision. The residuals from the second equation (the FSR in ivreg2) are not. Ergo, the overid stat differs. I will not disable the use of overid after reg3 options such as 2sls, but I think I will add a warning that the statistic is designed for use in 3SLS, and may not be applicable elsewhere.


Kit Baum   |   Boston College Economics & DIW Berlin   |
                              An Introduction to Stata Programming  |
   An Introduction to Modern Econometrics Using Stata  |

*   For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index