Dear all,
A (probably silly) question about the bootstrap command.
When trying to bootstrap a coefficient, one can save the estimated coefficient for each resampling/bootstrap iteration, and pile them up in a dataset.
When summarizing the aforementioned coefficient , I get an average that is different from the bootstrap results (while the sd are exactly identical.)
Below is an example that hopefully will illustrate/clarify:
Could you please help me understand why the su _bs_1 yields a different value compared to the results returned by the bootstrap ?
Thanks a lot,
Alex.
A (probably silly) question about the bootstrap command.
When trying to bootstrap a coefficient, one can save the estimated coefficient for each resampling/bootstrap iteration, and pile them up in a dataset.
When summarizing the aforementioned coefficient , I get an average that is different from the bootstrap results (while the sd are exactly identical.)
Below is an example that hopefully will illustrate/clarify:
Code:
cap program drop Test program define Test, rclass preserve reg price mpg weight length clear return scalar coeff = _b[mpg]/_b[weight] end sysuse auto, clear bootstrap r(coeff), reps(50) seed(123) saving(bla, replace): Test use bla, clear su _bs_1
Thanks a lot,
Alex.
Comment