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

re: st: -xtmixed- and random terms nested within fixed treatment terms?


From   David Airey <[email protected]>
To   [email protected]
Subject   re: st: -xtmixed- and random terms nested within fixed treatment terms?
Date   Thu, 16 Jun 2005 11:26:47 -0500

.

Have you seen the very helpful pages on xtmixed at UCLA? They are:

for classical experimental designs:

http://www.ats.ucla.edu/stat/stata/faq/xtmixed.htm

For the examples in Kreft and de Leeuw's textbook on multilevel modeling:

http://www.ats.ucla.edu/stat/stata/examples/mlm_imm/default.htm

For examples from Singer's paper using SAS but with other mixed model packages, including xtmixed:

http://www.ats.ucla.edu/stat/paperexamples/singer/default.htm

I don't know these answer your question.

-Dave



I have a uestion on the new xtmixed. I am trying to match a model run in S-Plux lme, and I am confused by the (lack of) nesting in
-xtmixed-

Suppose I have subjects assigned to treatment with outcomes measured at repeated occasions, and a covariate. It seems that the syntax for -xtmixed- should be something like this, where id (treatment) indicates nesting of id within treatment:

xtmixed outcome covariate treatment occasion || subject(treatment):

I might expect an adaptation of the example for xtmixed on page 184 [XT] to look like this:

xtmixed weight preweight treatment week || id(treatment):

It seems to me that id must be nested in treatment, but treatment is a fixed effect, not random, so the following syntax would be incorrect:

xtmixed weight preweight treatment week || id : treatment

It does not seem possible to nest subject (as a random term) within treatment in -xtmixed-; which seems the appropriate specification. Am I incorrect in thinking that this nesting is necessary?


Thanks
Buzz Burhans

*
*   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–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index