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: Drawing sample using bootstrap


From   Fernando Rios Avila <f.rios.a@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: Drawing sample using bootstrap
Date   Tue, 16 Oct 2012 14:16:54 -0400

perhaps something like:
set seed 101
forvalues i=1/10 {
preserve
bsample
save bootsample`i', replace
restore
}
HTH
On Tue, Oct 16, 2012 at 1:15 PM, Melaku Fekadu <melaku.fekadu@gmail.com> wrote:
> Dear Statalisters,
> I want to draw 10 samples with replacement from my existing data and
> keep or save them. Does bootstrap do that? My objective is just to
> obtain 10 samples drawn from my data and save them. My data has 100
> individuals and 5 variables. How do I do so in Stata?
> Thanks,
> Melaku
> *
> *   For searches and help try:
> *   http://www.stata.com/help.cgi?search
> *   http://www.stata.com/support/faqs/resources/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/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


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