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   Buzz Burhans <[email protected]>
To   [email protected]
Subject   re: st: -xtmixed- and random terms nested within fixed treatment terms?
Date   Thu, 16 Jun 2005 13:29:39 -0400

David, thanks for this. I am looking at it and see if it makes sense to me. I remain unclear as to why the xtmixed does not nest the subjects in the treatment, as I believe both SAS Proc Mixed and S-Plus lme do for a similar design.

I will look closely at this, and some help I solicited off list, and see if it makes sense to me.

Thanks

Buzz Burhans


At 11:32 AM 6/16/2005 -0500, you wrote:

.

You said:

Suppose I have subjects assigned to treatment with outcomes
measured at repeated occasions, and a covariate.
This design is a simple one between one within split-plot with a
covariate. If we ignore the covariate, the ANOVA design would be,
from http://www.ats.ucla.edu/stat/stata/faq/xtmixed.htm:

/* spf-2.4    subjects nested in a */
/* between subjects: a             */
/* within  subjects: b             */

use http://www.ats.ucla.edu/stat/stata/examples/kirk/spf2-4, clear

/* anova code: */ anova y a / s|a b a*b /, repeated(b)

xi3 e.a*e.b

xtmixed y _Ia_2 _Ib_2 _Ib_3 _Ib_4 _Ia2Xb2 _Ia2Xb3 _Ia2Xb4 || s:

test _Ia_2

test _Ib_2 _Ib_3 _Ib_4

/* scale chi^2 as F-ratio to compare with anova */
display r(chi2)/r(df)

test _Ia2Xb2 _Ia2Xb3 _Ia2Xb4

display r(chi2)/r(df)



*
*   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/
Buzz Burhans
[email protected]


*
*   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