Mike,
It may be simpler to program yourself the Hausman-Taylor estimator (see below for a rough code). You can obtain cluster-robust standard errors and you can take advantage of the various diagnostics and tests for weak instruments provided by -ivregress- or -ivreg2-.
Rodolphe
********************
webuse psidextract,clear
*** Time-demeaned and Time-averaged variables ***
foreach var of varlist lwage wks south smsa ms exp exp2 occ ind union fem blk ed {
drop if `var'==.
}
global TVVARS " wks south smsa ms exp exp2 occ ind union "
global TIVARS "fem blk ed"
global EXOG "wks south smsa ms"
foreach var of varlist lwage $TVVARS $TIVARS{
egen P`var'=mean(`var'), by(id)
gen Q`var'=`var'-P`var'
}
*** First step ****
xtreg lwage $TVVARS , fe
predict e,e
egen sigmae=sum(e^2)
replace sigmae=sigmae/(e(N)-e(N_g))
*gen double sigmae=e(rss)/(e(N)-e(N_g))
gen n=e(N_g)
predict d,u
*** Second step ****
ivreg2 d fem blk (ed= $EXOG )
gen double sigmas=e(rss)/n
gen obs=1
by id: gen double Ti = sum(obs)
by id: replace Ti = . if _n!=_N
summ Ti, meanonly
by id : gen double T_inv=1/Ti
summ T_inv, meanonly
gen double Tbar = 1/r(mean)
by id: replace Ti = Ti[_N]
gen double sigmau= (sigmas-sigmae)/Tbar
*** Third step ****
gen double theta = 1 - sqrt(sigmae/(Ti*sigmau+sigmae))
foreach var of varlist lwage $TVVARS $TIVARS {
gen double theta`var'=`var'-(theta)*P`var'
gen temp`var'=`var'
replace `var'=theta`var'
}
gen double cons=1-theta
*** Fourth step ****
*DEFAULT SE*
ivregress 2sls lwage wks south smsa ms fem blk ( exp exp2 occ ind union ed = Pwks Psouth Psmsa Pms Qexp Qexp2 Qocc Qind Qunion ) cons, small nocons
estimates store IVREGDEF
*ROBUST SE*
ivregress 2sls lwage wks south smsa ms fem blk ( exp exp2 occ ind union ed = Pwks Psouth Psmsa Pms Qexp Qexp2 Qocc Qind Qunion ) cons, small nocons r
estimates store IVREGROB
*CLUSTER-ROBUST SE*
ivregress 2sls lwage wks south smsa ms fem blk ( exp exp2 occ ind union ed = Pwks Psouth Psmsa Pms Qexp Qexp2 Qocc Qind Qunion ) cons, small nocons r cl(id)
estimates store IVREGCL
foreach var of varlist lwage $TVVARS $TIVARS {
replace `var'=temp`var'
}
*XTHATYLOR*
xthtaylor lwage wks south smsa ms exp exp2 occ ind union fem blk ed, endog(exp exp2 occ ind union ed) constant(fem blk ed)
estimates store XTHTAYLOR
estimates table XTHTAYLOR IVREGDEF IVREGROB IVREGCL ,b(%9.4f) se
*******************
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Mike Kim
Sent: lundi 24 août 2009 18:19
To: [email protected]
Subject: st: Re: RE: Stata11 cannot estimate xthtaylor with bootstrap SE
My data is panel data. So, I want to account for possible serial correlation
and heteroskedascity.
Mike.
----- Original Message -----
From: "Rodolphe Desbordes" <[email protected]>
To: <[email protected]>
Sent: Monday, August 24, 2009 12:04 PM
Subject: st: RE: Stata11 cannot estimate xthtaylor with bootstrap SE
Mike,
Are you using the bootstrap to obtain "robust" estimates of the standard
errors?
Rodolphe
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Mike Kim
Sent: lundi 24 août 2009 16:58
To: [email protected]
Subject: st: Stata11 cannot estimate xthtaylor with bootstrap SE
Dear all,
I am estimating 'xthtaylor" with bootstrap standard error.
xthtaylor depvar indepvars, endog(vars) vce(boot)
Stata10 gives estimation results with the following notation.
Bootstrap replications (50)
----+--- 1 ---+--- 2 ---+--- 3 ---+--- 4 ---+--- 5
.....xx....x..xx.x......x.x........xx.x...x....x.. 50
However, Stata11 cannot estimate the model. It says:
o. operator not allowed
an error occurred when bootstrap executed xthtaylor
r(101);
http://www.stata.com/support/faqs/lang/post.html says:
"As of Stata 11, variables are no longer dropped because of collinearity.
Instead, these variables are omitted and are labeled with the "o." operator
in the column names of the resulting parameter vector."
My questions are:
1. What does "xx...x..xx" mean in Stata10?
2. Why can't Stata11 estimate the model with the same code?
3. What is the difference between "dropping" and "omitting" a variable due
to collinearity?
Thank you for your help in advance.
Mike.
*
* 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/
*
* 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/