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

st: AW: clogit vs. logit

From   "Martin Weiss" <[email protected]>
To   <[email protected]>
Subject   st: AW: clogit vs. logit
Date   Tue, 10 Nov 2009 10:05:14 +0100


When I try your lines 

keep if (id==1)
clogit IV DV1 DV2, group(id)

with the example in the help file for -clogit-, I just can`t get

webuse lowbirth2, clear
keep if pairid==1
clogit low lwt smoke ptd ht ui i.race, group(pairid)

Is this what you mean by "Unfortunately the clogit doesn't work for all


-----Ursprüngliche Nachricht-----
Von: [email protected]
[mailto:[email protected]] Im Auftrag von Regina Kemmler
Gesendet: Dienstag, 10. November 2009 09:57
An: [email protected]
Betreff: st: clogit vs. logit

Dear Statalist,

I'd like to conduct a clogit analysis.
I have a sample of several household for whom I'd like to calculate the beta
coefficient for 4 different models and conduct the likelihood ratio test
afterwards to test which model fits best. Unfortunately the clogit doesn't
work for all models. But as the clogit and logit are supposed to give the
same results given you have one group I did the following syntax.

keep if (id==1)
clogit IV DV1 DV2, group(id)
gen b1_DV1=_b[DV1]
gen b1_DV2=_b[DV2]
gen lik1=e(ll) 
estimates store m1

logit IV DV2
gen b2_DV2=_b[DV2]
gen kons2=_cons
gen lik2=e(ll)
estimates store m2

logit IV DV1
gen b3_DV=_b[DV]
gen kons3=_cons
gen lik3=e(ll)
estimates store m3

logit IV
gen kons4=_cons
gen lik4=e(ll)
estimates store m4

lrtest m1 (m2 m3 m4), stats

Is it okay to mix up clogit and logit? Does it really give the same results?
Why is it then not possible to calculate clogit on the latter 3 models? And:
is it possible to conduct a likelihood ratio test if I mix up clogit and

Your help is much appreciated!
Thanks a lot,

Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3.5 -
sicherer, schneller und einfacher!
*   For searches and help try:

*   For searches and help try:

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