I am happy to announce a new Stata command, dbs, which allows the computation of double bootstrap confidence intervals. The command is easy to use, very similar to bootstrap, lightweight and supports multiple threads. For more information please refer to the documentation file (help dbs) or the Github page.
Installation
Code:
net install dbs, from(https://raw.github.com/fbittmann/dbs/stable) replace
Code:
. sysuse auto, clear
(1978 Automobile Data)
. dbs r(mean) r(p50): summarize mpg, detail
Warning: Because the command invoked does not set e(sample),
dbs has no way to determine which observations are
used incalculating the statistics and so assumes
that all observations are used. Check for missing
values with care.
Bootstrap replications (100 / 20)
----+--- 1 ---+--- 2 ---+--- 3 ---+--- 4 ---+--- 5
..........
Bootstrap results Number of obs = 74
Reps1 = 100
Reps2 = 20
command: summarize mpg, detail
_bs_1: r(mean)
_bs_2: r(p50)
---------------------------------------------------------------------------------
| Observed Coef. Boot. Std. Err. Bias SFrancia [95% Conf. Interval]
----------+----------------------------------------------------------------------
_bs_1 | 21.2973 0.6301 -0.075 0.963 20.1315 22.8198
_bs_2 | 20.0000 0.9891 0.095 0.561 16.9322 22.4864
---------------------------------------------------------------------------------
0 Response to dbs: Stata command for computing double bootstrap confidence intervals
Post a Comment