From | Richard Williams <[email protected]> |
To | [email protected] |
Subject | Re: st: error in logistic regression when fitting models |
Date | Sun, 06 Feb 2005 20:09:47 -0500 |
At 07:47 PM 2/6/2005 -0500, [email protected] wrote:
I am using logistic regression with Stata 8.1 to build models for prediction of infection risk. Stata runs the full model. Then, by removing variables (using p<0.2), I create new models, step by step. However, at some moment, after to run the "lrtest" command (in order to fitting both unconstrained and constrained models), Stata accuses an error (number 498) informing that the two last models have different observation numbers. What I have to do? In order to outline this trouble, can you propose me some procedure? It follows a sequence of commands that I am executing and the problem that occurs.The Ns differ because your variables have differing amounts of missing data; as you drop variables you regain cases. Specifically, asa has missing cases. Since you start with the most complex model first, probably the easiest thing to do is add
© Copyright 1996–2024 StataCorp LLC | Terms of use | Privacy | Contact us | What's new | Site index |