[S] Fast algorithm for approximate Bayesian bootstrap sought

Frank E Harrell Jr (fharrell@virginia.edu)
Wed, 5 Aug 1998 07:55:34 -0400


In the context of multiple imputation when least squares
regression is used for imputing missing variables, Rubin's
approximate Bayesian bootstrap (e.g. Stat in Med 10:585,1991)
algorithm is as follows, where n is the number of complete
observations and m is the number of missing observations on
the target variable:

for(imputation.number in 1:number.of.multiple.imputations) {

Compute residuals from n observations, off of predictions for the
target variable

Sample with replacement n of these n residuals
Sample with replacement m of these n sampled with replacement
Add these m random residuals to the predicted expected values of
the target variable

fit the model on the completed dataset for this imputation.number
}

If we weren't doing multiple imputation,
sample(sample(res,n,rep=T), m, rep=T)
would do the trick. But I want to quickly form an m x number.of
multiple.imputations matrix of residuals without a for loop.

I'll post a summary of solutions that are E-mailed to me.

Thanks -Frank Harrell

-----------------------------------------------------------------------
This message was distributed by s-news@wubios.wustl.edu. To unsubscribe
send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
message: unsubscribe s-news