Professional Documents
Culture Documents
M320
Cross Section and Panel Data Econometrics
Topic 2: Generalized Method of Moments
Part III: Testing
Dr. Melvyn Weeks
Faculty of Economics and Clare College
University of Cambridge
Outline
Outline
1
2
3
5
6
7
2
Motivation
The General Validity of Moment Restrictions
The Anatomy of 2SLS
The Bias of 2SLS
2SLS Bias and Weak Instruments
The Wald Estimator
The BJB Critique
Tests of Exogeneity and Weak Instruments
Overidentification Tests
A Test of a Subset of Orthogonality Conditions
A Test of Weak Identification
GMM Distance Tests of Endogeneity and Exogeneity
Endogeneity and the Linear Model
Isolating the effect of Education on wages from Ability
The Costs of GMM
Notes
Outline
Notes
Readings:
Angrist, J. and A. Krueger (1991). Does Compulsory
Schooling Attendance Affect Schooling and Earnings.
Quarterly Journal of Economics, 106, 979-1014.
Bekker, P. (1994). Alternative Approximations to the
Distribution of Instrumental Variables Estimators,
Econometrica 62, 657-681.
Bound, J., A. Jaeger and R. Baker (1996). Problems with
Instrumental Variables Estimation When the Correlation
Between the Instruments and the Endogenous Explanatory
Variable is Weak, Journal of the American Statistical
Association 90, 443-450.
Cameron, A.C. and P.K. Trivedi (2004). Microeconometrics:
Methods and Applications, Cambridge University Press
[Chapter 21]
3
Outline
Notes
Motivation
Notes
Remark
... An important cost of performing IV estimation when
x and are uncorrelated: the asymptotic variance of the
IV estimator is always larger, and sometimes much larger,
than the asymptotic variance of the OLS estimator
Wooldridge (2006), p.490. Introductory Econometrics: A Modern
Approach. 3rd Ed. New York: Thomson Learning.
Notes
Road Map
Notes
Remark
We consider tests for instrument relevance, instrument exogeneity
and instrument weak exogeneity.
For instrument exogeneity we consider a of class of
overidentification tests that may be used with 2sls and GMM
estimators
In considering tests of weak instruments our point of departure is
the bias of 2sls. Although well known, since the early 1990s
empirical researchers have realised that this bias can be significant
when instruments are weak.
We will see that in finite samples IV estimates are biased in the
same direction as OLS, with the bias dependent on the fit of the
first-stage regression
We examine the in-famous Angrist Kruger (1991) study on returns
to education and operationalise all these tests with some real data.
7
Notes
Notes
Notes
(1)
10
Notes
11
Notes
Remark
Below we examine the nomenclature of the 2SLS estimator.
We show that the 2SLS is biased in finite samples
We first do this for a single instrument
The bias is magnified by the problem of weak instruments
..
12
Notes
Revision
1
(2)
ei = zi + 1i
(3)
Reduced form:
yi = + zi + ri
(4)
13
Notes
yi
=
=
=
=
+ ei + i
+ (zi + 1i ) + i
+ zi + ( 1i + i )
+ zi + ri
= + b
ei + 2i
= + b
ei + (i + (ei b
ei ))
where b
ei = p
bzi denotes the first stage fitted values.
The estimator of in (5) is the IV estimator.
14
(5)
Notes
Remark
Bias in the 2sls estimator follows because the first stage is
estimated. Consider
e = z + 1
If were known then b
e = z.
These fitted values are uncorrelated with the second stage errors
For unknown , b
e =b
z.
b
e = zb
= Pz e
= z + Pz 1
Pz = z ( z 0 z ) 1 z 0 .
For endogenous e, Pz 1 is correlated with , resulting in a biased
2sls estimator.
15
= (e 0 PZ e )1 0 Z 0 + (e 0 PZ e )1 10 PZ
16
Notes
Notes
= (E [e 0 PZ e ])1 E [ 10 PZ ].
Substitute in the first stage again.
E [b
2SLS ] (E [0 Z 0 + 10 )PZ (Z + 1 )])1 E [ 10 PZ ].
Note that E [0 Z 0 1 ] = 0, so we get no cross-terms:
E [b
2SLS ] [E (0 Z 0 Z ) + E ( 10 PZ 1 )]1 E ( 10 PZ ).
17
Notes
1 1
2 F + 1
(6)
1
2
1
18
Notes
Remark
When instruments are weak the finite (and large) sample bias of
2sls is accentuated.
When instruments are weak 2sls standard errors are biased
downwards.
[Recall: When instruments are valid, adding instruments can
reduce the variance of the two-stage least squares estimator.]
Weak instruments: confidence can be misleading in that the
mid-point is biased and their width too narrow
19
Notes
(0.0105)
20
Notes
= xi0 + i
= wi0 1 + ei 2 + i
21
Notes
2SLS
b
2,2SLS
22
Notes
1st Quarter
4th Quarter
Difference
12.688
5.892
12.840
5.905
0.151
0.014
0.089
Real QOB
Random QOB
0.089
1.958
(0.011)
(18.116)
500 Instruments
TSLS
LIML
0.073
0.059
(0.008)
(0.085)
0.095
0.330
(0.017)
(0.1001)
23
Notes
24
Notes
Exam Question
Consider the following linear regression
yi
Si
= Si + i
= zi + i
25
Notes
26
Coefficient
(1)
OLS
(2)
IV
(3)
IV
(4)
IV
.063
(.000)
.142
(.033)
.081
(.016)
.083
(.009)
13.486
4.747
2.428
x
x
x
x
x
180
FE
Notes
Age, Age2
9 Year of birth dummies
Excluded instruments
x
Quarter of birth
Quarter of birth year of birth
Quarter of birth state of birth
Number of excluded instruments
30
Calculated from the 5% Public-Use Sample of the 1980 US Census for men born 1930-1938.
Sample size is 329,509. All specifications include Race (1=black), SMSA (1=central city),
Married (1 = married, living with spouse), and 8 Regional dummies as control variables.
Column 4 also includes 50 state dummies as controls.
SMSA denotes Standard Metropolitan Statistical Area.
27
1
N
i =1
Notes
(7)
i =1
b 1
Cc
N =S
b = Var(N 1 (wi , b
S
))
i
A general model specification test can be used where M > K .
This is a test of the population moment conditions.
H0 : E [(w, 0 )] = 0
b i , to 0, where
b i = (w i , b
- test closeness of n1
).
Just-identified models
b i = 0 is imposed and the test is not possible.
n 1
Over-identified models
b ij = 0, j = 1, ..., M
Cannot set all n1
28
(8)
Notes
Remark
Under H0 : E [(w, 0 )] = 0, the value of QC () evaluated at the
efficient GMM estimator (b
GMM ) 2(M K )
Using this statistic, and for M > K , we can evaluate whether all
(or a subset) of the moment conditions (OC) are valid.
These are tests of overidentifying restrictions.
There are M K of them.
29
Overidentification Tests
Notes
Remark
the overidentification test is a test of whether all the moment
conditions are satisfied.
If QC () is large either the moment conditions or the other model
assumptions (or both) are likely to be false.
Only if we are confident about the other assumptions can we
interpret a large value of QC (.) as evidence of the endogeneity of
some of the instruments in xi
Remark
Hansens J statistic is consistent in the presence of
heteroskedasticity; Sargans statistic is not.
30
Overidentification Tests
Notes
Example
Taking the linear model as an example. Given the null hypothesis
H0 : E [(w, 0 )] = 0
(9)
then
1
b 1 [ 1 Z0 (y X)]
QC () = [ Z0 (y X)]0 C
N
n
n
a 2
(M k )
We will reject the overidentifying restrictions if the p-value
Pr(2(M k ) QC ())
(10)
31
Notes
Notes
Notes
Remark
One obvious informal test of weak instruments is to simply
correlate the set of instruments with the endogenous variable(s)
This will create pairwise correlation statistics.
The joint correlation across a set of multiple instruments can be
represented by the R 2 statistic from the first stage regression.
A test of identification A measure of the joint significance of a
set of instruments z is the F statistic.
A test of weak identification A rule of thumb suggested by
Staiger and Stock (1997):
an F statistic of less than 10 may indicate weak instruments.
34
Notes
Notes
36
y
y
x1
x1
x2
x2
(x3
(x3
=
=
z1
z1
z2
z3
z3
z4)
z4),
orthog(z2)
Notes
(11)
b c ) Var (
b e ))
G = (Var (
b ) is a consistent estimate of the asymptotic variance of ;
Var (
?
G denotes a generalized inverse.
H 2ke ; ke denotes number of regressors tested for endogeneity.
37
Notes
Remark
For a discussion of
- the Durbin-Wu-Hausman test of the endogeneity of regressors
- the generalisation of this test to subsets of regressors, and
- how the Hausman form of this test may be interpreted as a GMM
test
see Baum, C., M. Schaffer, and S. Stillman (2003)
38
Notes
(12)
yi is N 1 and xi is N K
zi is a N r matrix of instruments.
zi satisfies the moment conditions
E [zi i ] = 0
(13)
zi0 i
#0
"
CN
i =1
zi0 i
#
(14)
i =1
Remark
ivreg2 provides extensions to Statas official ivreg. ivreg2 shares
the same command syntax as official ivreg and supports (almost)
all of its options.
Differences between ivreg2 and ivreg : optional two-step feasible
GMM estimation (gmm option); automatic output of the
Hansen-Sargan statistic for overidentifying restrictions;
40
Notes
Notes
41
Notes
IVREG2
The gmm option implements the two-step efficient generalized
method of moments (GMM) estimator.
Efficiency gains of this estimator relative to the IV/2SLS estimator
derive from the use of the optimal weighting matrix.
Efficient GMM estimator: robust to the presence of
heteroskedasticity of unknown form
cluster option chosen, efficient GMM estimator uses a
cluster-robust optimal weighting matrix and the estimator is also
robust to arbitrary intra-cluster correlation.
Assumption of conditional homoskedasticity: efficient GMM
estimator becomes the traditional 2SLS estimator.
42
Notes
Notes
zi2 = (Si )
2
3
4
b
Compute J and the 5 5 matrix S
b1 (from S)
b corresponding to zi1 .
Extract the 4 4 submatrix S
Estimate the same coefficient by GMM with reduced set of
instruments.
Difference in J statistic from two different GMM a 2 (1)
Why is age predetermined here?
44
(15)
Notes
45
Notes
46
Notes
* Reproduce line 5 of table *, Hayashi (2000)
** standard IV/2SLS estimator with asymptotic standard errors
** - assumption - conditionally homoscedastic/independent errors
ivreg2 lw expr tenure rns smsa _I* (iq s = med kww mrt age)
** IV/2SLS estimator: robust to heteroscedasticity
** - robust option: Sargan statistic changes to Hansen J
ivreg2 lw expr tenure rns smsa _I* (iq s = med kww mrt age), robust
** IV/2SLS estimator: robust to heteroscedasticity
** small
ivreg2 lw expr tenure rns smsa _I* (iq s = med kww mrt age) , robust small
* Reproduce line 5 of table *, Hayashi (2000)
** 2 step GMM estimator: robust to heteroscedasticity
ivreg2 lw expr tenure rns smsa _I* (iq s = med kww mrt age) , gmm2s robust
47
Notes
** Testing Exogeneity of
Regressors or Instruments
lw expr tenure rns smsa _I* (iq s = med kww mrt age), orthog(rns)
ii) ivreg2
lw expr tenure rns smsa _I* (iq s = med kww mrt age), endog(rns)
48
Notes
Remark
IV estimates of the standard errors are inconsistent in the presence
of heteroscedasticity, thereby compromising valid inference.
Standard diagnostic tests for endogeneity and overidentification are
also invalid.
The usual approach when facing heteroscedasticty of unknown
form is to use GMM.
Efficient GMM is consistent in the presence of arbitrary
heteroscedasticty, but at a cost of poor finite sample performance.
If heteroscedasticty is not present, then standard IV may be
preferable.
49
Notes
50