Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
From | David Hoaglin <dchoaglin@gmail.com> |
To | statalist@hsphsun2.harvard.edu |
Subject | Re: st: Treating ind. vars in logit |
Date | Sat, 20 Apr 2013 11:11:45 -0400 |
After fitting the model with i.x as the predictor, it would be a good idea to plot the coefficients of Categories 1 through 5 (with 0 as the value for the reference category, Category 1) against the coded values for those categories. Also take into account the confidence intervals for the coefficients. The plot (for each of the three ordered categorical variables) should provide an indication of whether it's reasonable to use x as a linear predictor, whether it would be appropriate to combine some categories, or whether the effects of the variable follow some other pattern. Do the data have any evidence of interactions among those three variables? (Note the use of the -force- option, because m1 is not a sub-model of m2.) David Hoaglin On Sat, Apr 20, 2013 at 10:11 AM, Richard Williams <richardwilliams.ndu@gmail.com> wrote: > I would code it as 1 to 5. It wouldn't be unusual just to treat it as continuous. If you want to do a formal test of whether or not that is legit, do something like > > logit y x > est store m1 > logit y i.x > est store m2 > lrtest m1 m2, force > > If the difference is not significant treating as continuous is ok. Even if it is significant you can assess how horrible it is to treat as continuous, e.g. how much do the predicted values differ under the two models? * * 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/