CHAPTER 16 - Simultaneous Equations Models#
import stata_setup
stata_setup.config("C:/Program Files/Stata18/", "se" ,splash=False)
Example 16.1 Murder Rates and Size of the Police Force#
NA
Example 16.2 Housing Expenditures and Saving#
NA
Example 16.3 Labor Supply of Married, Working Women#
NA
Example 16.4 Inflation and Openness#
NA
Example 16.5 Labor Supply of Married, Working Women#
%%stata
u mroz, clear
ivreg hours (lwage=exper*) educ age kidslt6 nwifeinc
ivreg lwage (hours= age kidslt6 nwifeinc) educ exper*
. u mroz, clear
. ivreg hours (lwage=exper*) educ age kidslt6 nwifeinc
Instrumental variables 2SLS regression
Source | SS df MS Number of obs = 428
-------------+---------------------------------- F(5, 422) = 3.44
Model | -516582103 5 -103316421 Prob > F = 0.0046
Residual | 773893123 422 1833869.96 R-squared = .
-------------+---------------------------------- Adj R-squared = .
Total | 257311020 427 602601.92 Root MSE = 1354.2
------------------------------------------------------------------------------
hours | Coefficient Std. err. t P>|t| [95% conf. interval]
-------------+----------------------------------------------------------------
lwage |
1639.556 470.5757 3.48 0.001 714.5914 2564.52
educ | -183.7513 59.09981 -3.11 0.002 -299.9179 -67.58462
age | -7.806092 9.378013 -0.83 0.406 -26.23953 10.62734
kidslt6 | -198.1543 182.9291 -1.08 0.279 -557.7201 161.4115
nwifeinc | -10.16959 6.614743 -1.54 0.125 -23.17154 2.832358
_cons | 2225.662 574.5641 3.87 0.000 1096.298 3355.026
------------------------------------------------------------------------------
Endogenous: lwage
Exogenous: educ age kidslt6 nwifeinc exper expersq
. ivreg lwage (hours= age kidslt6 nwifeinc) educ exper*
Instrumental variables 2SLS regression
Source | SS df MS Number of obs = 428
-------------+---------------------------------- F(4, 423) = 19.03
Model | 28.0618831 4 7.01547077 Prob > F = 0.0000
Residual | 195.265558 423 .461620704 R-squared = 0.1257
-------------+---------------------------------- Adj R-squared = 0.1174
Total | 223.327441 427 .523015084 Root MSE = .67943
------------------------------------------------------------------------------
lwage | Coefficient Std. err. t P>|t| [95% conf. interval]
-------------+----------------------------------------------------------------
hours | .0001259 .0002546 0.49 0.621 -.0003746 .0006264
educ | .11033 .0155244 7.11 0.000 .0798155 .1408445
exper | .0345824 .0194916 1.77 0.077 -.00373 .0728947
expersq | -.0007058 .0004541 -1.55 0.121 -.0015983 .0001868
_cons | -.6557254 .3377883 -1.94 0.053 -1.319678 .0082272
------------------------------------------------------------------------------
Endogenous: hours
Exogenous: educ exper expersq age kidslt6 nwifeinc
.
Example 16.6 Inflation and Openness#
%%stata
u openness, clear
reg open lpcinc lland
ivreg inf (open=lland) lpcinc
. u openness, clear
. reg open lpcinc lland
Source | SS df MS Number of obs = 114
-------------+---------------------------------- F(2, 111) = 45.17
Model | 28606.1936 2 14303.0968 Prob > F = 0.0000
Residual | 35151.7966 111 316.682852 R-squared = 0.4487
-------------+---------------------------------- Adj R-squared = 0.4387
Total | 63757.9902 113 564.230002 Root MSE = 17.796
------------------------------------------------------------------------------
open | Coefficient Std. err. t P>|t| [95% conf. interval]
-------------+----------------------------------------------------------------
lpcinc | .5464812 1.49324 0.37 0.715 -2.412473 3.505435
lland | -7.567103 .8142162 -9.29 0.000 -9.180527 -5.953679
_cons | 117.0845 15.8483 7.39 0.000 85.68005 148.489
------------------------------------------------------------------------------
. ivreg inf (open=lland) lpcinc
Instrumental variables 2SLS regression
Source | SS df MS Number of obs = 114
-------------+---------------------------------- F(2, 111) = 2.79
Model | 2009.22775 2 1004.61387 Prob > F = 0.0657
Residual | 63064.194 111 568.145892 R-squared = 0.0309
-------------+---------------------------------- Adj R-squared = 0.0134
Total | 65073.4217 113 575.870989 Root MSE = 23.836
------------------------------------------------------------------------------
inf | Coefficient Std. err. t P>|t| [95% conf. interval]
-------------+----------------------------------------------------------------
open | -.3374871 .1441212 -2.34 0.021 -.6230728 -.0519014
lpcinc | .3758247 2.015081 0.19 0.852 -3.617192 4.368842
_cons | 26.89934 15.4012 1.75 0.083 -3.619162 57.41783
------------------------------------------------------------------------------
Endogenous: open
Exogenous: lpcinc lland
.
Example 16.7 Testing the Permanent Income Hypothesis#
%%stata
u consump, clear
ivreg gc (gy r3 =gy_1 gc_1 r3_1)
predict u, res
g u_1 = u[_n-1]
reg u u_1
ivreg gc (gy r3 =gy_1 gc_1 r3_1) u_1 //Note the difference with the answer in the text book.
. u consump, clear
. ivreg gc (gy r3 =gy_1 gc_1 r3_1)
Instrumental variables 2SLS regression
Source | SS df MS Number of obs = 35
-------------+---------------------------------- F(2, 32) = 9.59
Model | .00375939 2 .001879695 Prob > F = 0.0005
Residual | .001786211 32 .000055819 R-squared = 0.6779
-------------+---------------------------------- Adj R-squared = 0.6578
Total | .005545602 34 .000163106 Root MSE = .00747
------------------------------------------------------------------------------
gc | Coefficient Std. err. t P>|t| [95% conf. interval]
-------------+----------------------------------------------------------------
gy | .586188 .1345737 4.36 0.000 .3120703 .8603057
r3 | -.0002694 .000764 -0.35 0.727 -.0018257 .0012869
_cons | .0080597 .0032327 2.49 0.018 .0014748 .0146446
------------------------------------------------------------------------------
Endogenous: gy r3
Exogenous: gy_1 gc_1 r3_1
. predict u, res
(1 missing value generated)
. g u_1 = u[_n-1]
(2 missing values generated)
. reg u u_1
Source | SS df MS Number of obs = 35
-------------+---------------------------------- F(1, 33) = 0.37
Model | .00001996 1 .00001996 Prob > F = 0.5456
Residual | .001766252 33 .000053523 R-squared = 0.0112
-------------+---------------------------------- Adj R-squared = -0.0188
Total | .001786211 34 .000052536 Root MSE = .00732
------------------------------------------------------------------------------
u | Coefficient Std. err. t P>|t| [95% conf. interval]
-------------+----------------------------------------------------------------
u_1 | -.1083367 .1774061 -0.61 0.546 -.4692721 .2525987
_cons | .0000353 .001238 0.03 0.977 -.0024833 .002554
------------------------------------------------------------------------------
. ivreg gc (gy r3 =gy_1 gc_1 r3_1) u_1 //Note the difference with the answer in
> the text book.
Instrumental variables 2SLS regression
Source | SS df MS Number of obs = 35
-------------+---------------------------------- F(3, 31) = 4.10
Model | .002572473 3 .000857491 Prob > F = 0.0146
Residual | .002973128 31 .000095907 R-squared = 0.4639
-------------+---------------------------------- Adj R-squared = 0.4120
Total | .005545602 34 .000163106 Root MSE = .00979
------------------------------------------------------------------------------
gc | Coefficient Std. err. t P>|t| [95% conf. interval]
-------------+----------------------------------------------------------------
gy | .9826985 .4108234 2.39 0.023 .1448188 1.820578
r3 | -.0004122 .0010104 -0.41 0.686 -.0024729 .0016485
u_1 | -.5945359 .5563222 -1.07 0.293 -1.729162 .5400906
_cons | -.0003251 .0089171 -0.04 0.971 -.0185116 .0178613
------------------------------------------------------------------------------
Endogenous: gy r3
Exogenous: u_1 gy_1 gc_1 r3_1
.