solution - Jean-Pierre Laffargue's home page
11 Feb 2011 ... EXAMEN D'ECONOMETRIE APPLIQUEE. Question 1 . use "C:Documents and
SettingsAdministradorMis documentosInternational ...
Part of the document
M2R Economie internationale, développement, transition Année 2010-
2011 EXAMEN D'ECONOMETRIE APPLIQUEE
Question 1 [pic] . use "C:\Documents and Settings\Administrador\Mis documentos\International
Economics I\Econometrics\Laffargue\exam\mus06
> data.dta", clear . describe ldrugexp hi_empunion totchr age female blhisp linc storage display value
variable name type format label variable label
----------------------------------------------------------------------------
---------------------------------------------
ldrugexp float %9.0g log(drugexp)
hi_empunion byte %8.0g Insured thro emp/union
totchr byte %8.0g Total chronic cond
age byte %8.0g Age
female byte %8.0g Female
blhisp float %9.0g Black or Hispanic
linc float %9.0g log(income)
. sum ldrugexp hi_empunion totchr age female blhisp linc Variable | Obs Mean Std. Dev. Min Max
-------------+--------------------------------------------------------
ldrugexp | 10391 6.479668 1.363395 0 10.18017
hi_empunion | 10391 .3796555 .4853245 0 1
totchr | 10391 1.860745 1.290131 0 9
age | 10391 75.04639 6.69368 65 91
female | 10391 .5797325 .4936256 0 1
-------------+--------------------------------------------------------
blhisp | 10391 .1703397 .3759491 0 1
linc | 10089 2.743275 .9131433 -6.907755 5.744476
We can see that the variable linc is contains missing observations. We can
also see that the average age of individuals in the sample is 75 years, and
that less than 50% of them have a complementary insurance. More than half
of them are females. Proportion of blacks and Hispanics is not that high at
all.
Question 2 [pic] To know if there are missing observations we use codebook command and then
we the drop missing ones:
. codebook linc ----------------------------------------------------------------------------
---------------------------------------------
linc
log(income)
----------------------------------------------------------------------------
--------------------------------------------- type: numeric (float) range: [-6.9077554,5.7444763] units: 1.000e-09
unique values: 6914 missing .: 302/10391 mean: 2.74328
std. dev: .913143 percentiles: 10% 25% 50% 75% 90%
1.79176 2.2327 2.74316 3.31506 3.79928 . drop if linc==.
(302 observations deleted)
. des ssiratio lowincome firmsz multlc storage display value
variable name type format label variable label
----------------------------------------------------------------------------
---------------------------------------------
ssiratio float %9.0g SSI/Income ratio
lowincome byte %8.0g Low income
firmsz float %9.0g Firm size
multlc byte %8.0g Multiple locations
. sum ssiratio lowincome firmsz multlc Variable | Obs Mean Std. Dev. Min Max
-------------+--------------------------------------------------------
ssiratio | 10089 .5365438 .3678175 0 9.25062
lowincome | 10089 .1874319 .3902771 0 1
firmsz | 10089 .1405293 2.170389 0 50
multlc | 10089 .0620478 .2412543 0 1 We can see that the variable lowincome is not that high, meaning that the
status lowi ncome is rather represents a very small proportion of the
observations. We can also see that on average the ssiratio is not that
high, meaning that there is not a very high income constraint. We also find
that the size of the firms were the individuals are employed, on average
are rather small and not operating in much locations.
Question 3
. ivreg2 ldrugexp totchr age female blhisp linc ( hi_empunion= ssiratio ),
first robust
. ivreg2 ldrugexp totchr age female blhisp linc ( hi_empunion= ssiratio ),
first robust First-stage regressions
----------------------- First-stage regression of hi_empunion: OLS estimation
-------------- Estimates efficient for homoskedasticity only
Statistics robust to heteroskedasticity Number of obs =
10089
F( 6, 10082) =
119.18
Prob > F =
0.0000
Total (centered) SS = 2382.242839 Centered R2 =
0.0761
Total (uncentered) SS = 3856 Uncentered R2 =
0.4292
Residual SS = 2201.062524 Root MSE =
.4672 ----------------------------------------------------------------------------
--
| Robust
hi_empunion | Coef. Std. Err. t P>|t| [95% Conf.
Interval]
-------------+--------------------------------------------------------------
--
totchr | .0127865 .0036655 3.49 0.000 .0056015
.0199716
age | -.0086323 .0007087 -12.18 0.000 -.0100216
-.0072431
female | -.07345 .0096392 -7.62 0.000 -.0923448
-.0545552
blhisp | -.06268 .0122742 -5.11 0.000 -.08674
-.0386201
linc | .0483937 .0066075 7.32 0.000 .0354417
.0613456
ssiratio | -.1916432 .0236326 -8.11 0.000 -.2379678
-.1453186
_cons | 1.028981 .0581387 17.70 0.000 .9150172
1.142944
----------------------------------------------------------------------------
--
Included instruments: totchr age female blhisp linc ssiratio
----------------------------------------------------------------------------
--
F test of excluded instruments:
F( 1, 10082) = 65.76
Prob > F = 0.0000
Angrist-Pischke multivariate F test of excluded instruments:
F( 1, 10082) = 65.76
Prob > F = 0.0000
Summary results for first-stage regressions
------------------------------------------- (Underid) (Weak id)
Variable | F( 1, 10082) P-val | AP Chi-sq( 1) P-val | AP F( 1,
10082)
hi_empunion | 65.76 0.0000 | 65.81 0.0000 | 65.76 NB: first-stage test statistics heteroskedasticity-robust Stock-Yogo weak ID test critical values for single endogenous regressor:
10% maximal IV size 16.38
15% maximal IV size 8.96
20% maximal IV size 6.66
25% maximal IV size 5.53
Source: Stock-Yogo (2005). Reproduced by permission.
NB: Critical values are for Cragg-Donald F statistic and i.i.d. errors. Underidentification test
Ho: matrix of reduced form coefficients has rank=K1-1 (underidentified)
Ha: matrix has rank=K1 (identified)
Kleibergen-Paap rk LM statistic Chi-sq(1)=138.02 P-val=0.0000 Weak identification test
Ho: equation is weakly identified
Cragg-Donald Wald F statistic 183.98
Kleibergen-Paap Wald rk F statistic 65.76 Stock-Yogo weak ID test critical values for K1=1 and L1=1:
10% maximal IV size 16.38
15% maximal IV size 8.96
20% maximal IV size 6.66
25% maximal IV size 5.53
Source: Stock-Yogo (2005). Reproduced by permission.
NB: Critical values are for Cragg-Donald F statistic and i.i.d. errors. Weak-instrument-robust inference
Tests of joint significance of endogenous regressors B1 in main equation
Ho: B1=0 and orthogonality conditions are valid
Anderson-Rubin Wald test F(1,10082)= 22.12 P-val=0.0000
Anderson-Rubin Wald test Chi-sq(1)= 22.13 P-val=0.0000
Stock-Wright LM S statistic Chi-sq(1)= 20.71 P-val=0.0000 NB: Underidentification, weak identification and weak-identification-robust
test statistics heteroskedasticity-robust Number of observations N = 10089
Number of regressors K = 7
Number of endogenous regressors K1 = 1
Number of instruments L = 7
Number of excluded instruments L1 = 1 IV (2SLS) estimation
-------------------- Estimates efficient for homoskedasticity only
Statistics robust to heteroskedasticity Number of obs =
10089
F( 6, 10082) =
333.25
Prob > F =
0.0000
Total (centered) SS = 18715.11622 Centered R2 =
0.0640
Total (uncentered) SS = 442534.2012 Uncentered R2 =
0.9604
Residual SS = 17518.21658 Root MSE =
1.318 ----------------------------------------------------------------------------
--
| Robust
ldrugexp | Coef. Std. Err. z P>|z| [95% Conf.
Interval]
-------------+--