Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Leave the full dataset in memory when bootstraping


From   poastpd@umich.edu
To   statalist@hsphsun2.harvard.edu
Subject   st: Leave the full dataset in memory when bootstraping
Date   Fri, 30 May 2008 08:51:25 -0400

Hello,

I am creating a loop to run a probit model with boostrapped data (using the bsample command). Unfortunately, I find that with each iteration of my loop, the sample size decreases. Eventually, the sample size is so small that the loop crashes (due, most typically, to one of the independent variables perfectly predicting the dependent variable).

Using the "weight" option with "bsample" preserves the full dataset, but this creates another problem. Specifically, it causes STATA to pull the exact same sample with each iteration of the loop (which, of course, defeats the purpose of iterating the process).

Therefore, can anyone suggest a away to conduct a bootstrap, using the bsample command, that leaves the full dataset in memory and tells STATA to draw a different sample from the dataset with each iteration?

Many thanks in advance,

Paul




*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* 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   |   What's new   |   Site index