Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: Stepwise logistic regression with categorical variables


From   Thomas Trikalinos (.Mac) <ttrikalin@mac.com>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: Stepwise logistic regression with categorical variables
Date   Mon, 7 Jun 2004 17:48:18 +0300

try entering eg i.v25 in parentheses. This means that all the v25 dummies are considered together as a group:
xi: sw logistic status v3 i.v5 v6 v17 v18 v19 v21 (i.v25) v26 i.v27 i.v28 i.v29 i.v30 i.v31
Cheers

Tom

On Jun 7, 2004, at 17:37, Rachel Wade wrote:

Hello,
 
I am trying to carry out a stepwise logistic regression (I am aware of its limitations and am using it for exploratory purposes) and have a combination of categorical and continuous variables I wish to potentially include in a model. 
For example the line of code below:
xi: sw logistic status v3 i.v5 v6 v17 v18 v19 v21 i.v25 v26 i.v27 i.v28 i.v29 i.v30 i.v31

 
My question is how can I ensure that if the output contains a categorical variable (for example v25) that it contains the whole variable rather than just one or several of its categories, as this is no use to me.
 
I have looked in the help for xi and sw but find nothing on how to do this, yet I am sure that it must be possible.
 
Any assistance much appreciated,
 
With kind regards,
 
Rachel Wade



© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index