Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


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

Re: st: Observations differ


From   Brendan Halpin <brendan.halpin@ul.ie>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: Observations differ
Date   Sun, 23 Sep 2012 13:23:12 +0100

On Sun, Sep 23 2012, Shittu, Aminu wrote:

> Hi all
>
> I am trying to compare, using likelihood ratio test, between the full
> and reduced model in a random effect logistic regression; but the output
> is saying "observations differ: 3356 vs. 3583." How can I handle this
> problem, please.
>
> Aminu.

// fit the full model first
xtlogit y x1 x2 etc...
est store full
// fit the reduced model on the estimation sample of the full model
xtlogit y x1 etc... if e(sample)
lrtest full

You probably have cases that are missing on one or more of the
additional variables in the full model, which have full information on
all the variables in the reduced model.

Regards,

Brendan
-- 
Brendan Halpin,   Department of Sociology,   University of Limerick,   Ireland
Tel: w +353-61-213147  f +353-61-202569  h +353-61-338562;  Room F1-009 x 3147
mailto:brendan.halpin@ul.ie    ULSociology on Facebook: http://on.fb.me/fjIK9t
http://teaching.sociology.ul.ie/bhalpin/wordpress         twitter:@ULSociology
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


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