Statalist


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

st: Leave the full dataset in memory when bootstraping


From   [email protected]
To   [email protected]
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–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index