On Friday, Marieke asked:
> In order to validate internally and asses overfitting in a logistic
> regression model, I performed bootstrapping. However, I noticed that it is
> impossible to get the AUC (from lroc) for each repetition. Does anyone know
> how I can solve this.
>
We can write a small rclass program to save the area each time.
Here is an example:
program drop myboot
program myboot, rclass
logit for rep
lroc, nograph
ret list
return scalar area=r(area)
end
clear
sysuse auto
logit for rep
lroc, nograph
bootstrap "myboot" r(area), reps(5) saving(bootresults, replace)
clear
use bootresults
list
--May
[email protected]
*
* 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/