Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


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

Re: st: xthtaylor using vce(bootstrap, cluster(month)) when calculating SE


From   vwiggins@stata.com (Vince Wiggins, StataCorp)
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: xthtaylor using vce(bootstrap, cluster(month)) when calculating SE
Date   Tue, 13 Mar 2012 17:50:54 -0500

Marc Kramer <M.M.Kramer@rug.nl> asks about clustered bootstrap standard
errors using the command -xthtaylor-,

> A reviewer asked me make sure to control for cross-sectional
> dependence in my data an apply a bootstrap technique. Therefore, I
> use -vce(bootstrap, reps(250) seed(1))- after -xthtaylor-.
>
> Another reviewer asked to additionally apply the cluster option in
> the bootstrap command.  However, when I use -vce(bootstrap,
> cluster(month) reps(250) seed(1))- after -xthtaylor- Stata replies
> "option cluster() not allowed". Apperently this option cannot be
> executed when using Hausman-Taylor estimation.
>
> My question is if it possible with the -xthtaylor- command to use
> clustered standard errors when bootstrapping and if it would make
> sense?

It makes so much sense that it is the default for panel-data
estimators, including -xthtaylor-.  In fact, the -vce(bootstrap)-
option will only resample full panels -- the equivalent of the
bootstrap option -cluster(id)-.  Because panel-data estimators assume
that the observations within panel are correlated in some way, a
resampling of observation would also have to explicitly model that
correlation.  A "normal" bootstrap can account for the correlation by
not resampling observations, but instead resampling panels.  That is
what -xthtaylor- and other -xt- estimators do.

If Marc wants to use any bootstrap resampling other than resampling the
panels, he will need to use the -bootstrap- prefix.  I do not recommend
this, and neither does manual entry where bootstrapping panel data
estimators is explained -- "[XT] vce options".  If he uses the
-bootstrap- prefix, it would be up to Marc to account for the
within-panel correlations.

If Marc merely wants to prove to himself that that -vce(bootstrap)- is
clustering on panels, he can prefix his -xthtaylor- command with

    . bootstrap, cluster(id) idcluster(newid) seed(1): 

This assumes Marc's panel identifier is -id-.  He will also need to add
option -id(newid)- to his -xthtaylor- command.  Tricky, I admit, and
that is why we recommend using the -vce(bootstrap)- option.  The
trickiness is required because -bootstrap- must resample panels,
meaning that id's will be repeated, but still treat those duplicated
panels as separate panels, meaning we must create a new id, and tell
-xthtaylor- about that new id.  The -seed(1)- is just to match what
Marc was using in his -vce(bootstrap)- option so that the resampling
will be identical to his.


 
-- Vince 
   vwiggins@stata.com

 
*
*   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/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index