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

st: PROC MIXED


From   john smith <johninlouisville2004@yahoo.com>
To   statalist@hsphsun2.harvard.edu
Subject   st: PROC MIXED
Date   Wed, 17 Mar 2004 10:28:59 -0800 (PST)

I wanted to translate the following SAS code to STATA,
and not being a SAS expert wanted your suggestions.

PROC MIXED SCORING METHOD=ML COVTEST;
CLASS GROUP1  GROUP2 ID ;
MODEL Y=GROUP1  GROUP2 X3;
REPEATED / TYPE=UN SUBJECT=ID ;
LSMEANS GROUP1/PDIFF;

I am mainly interested in the results of the LSMEANS.
Note that GROUP1 is binary.  The observations are
unique when sorted by ID and GROUP2.

My attempt in Stata was to do the following.
iis ID
tis GROUP2
qui tab GROUP2, gen(_gr)
xtgee Y GROUP1 _gr* X3, corr(uns)

The coefficient on GROUP1 does not match the SAS
LSMEANS result.  What am I doing wrong?

Thanks.


__________________________________
Do you Yahoo!?
Yahoo! Mail - More reliable, more storage, less spam
http://mail.yahoo.com
*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   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   |   What's new   |   Site index