Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: bootstrap and predictive logistic model


From   Fabio Alberto Camargo Figuera <[email protected]>
To   [email protected]
Subject   st: bootstrap and predictive logistic model
Date   Mon, 21 Oct 2013 10:07:11 -0200

Hi.

I am developing a predictive logistic model.

The regression coefficients were selected using the stepwise method:

. xi: sw, lr pe(.05 ) pr(.051) lockterm1: logistic depvar (var1 i.var2) var3 (i.var4) var5
. lroc, nograph

depvar is the outcome
va2 and var4 re dummy variables, and I want to evaluate each as a whole, so I use the parentheses.
I want to force the inclusion of the variables var1 and var2

I would like to performed internal validation of the model by using a bootstrapping procedure and to study the stability of the stepwise selected model.

I am interested in determining which variables are consistently selected and to know the value of ROC curve within each sample using bootstrapping, and then correct the regression coefficients and ROC curve for optimism.

This with commands bootstrap or vce(bootstrap). I found swoot.ado on the web:

http://fmwww.bc.edu/repec/bocode/s/swboot.ado

But don't work for dummy variables.

How can I make sure that the two or three categories are either both included or both excluded
(instead of just one) at each sample repetition from bootstrap?

I already unsuccesfully tried creating my own dummy variables: (var2_dummy1 var2_dummy2 var2_dummy3) and (var4_dummy1 var4_dummy2 var4_dummy3). And also how do I force the inclusion of some variables? because the command lockterm does not work with swboot.

So, if anyone can help me, I appreciate it.

Thanks in advance.

Fabio.
*
*   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–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index