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

From |
"Michael I. Lichter" <mlichter@buffalo.edu> |

To |
statalist@hsphsun2.harvard.edu |

Subject |
Re: st: specifying random effects in -xtmixed- for pretest/posttest clustered design |

Date |
Fri, 03 Apr 2009 14:56:22 -0400 |

Michael Jeph Herrin wrote:

Try, xtmixed y cond t tc || g: cond t tc this tells -xtmixed- to estimate random effects across group for cond, t, and tc. I don't know what murray means by including M as a random effect (and don't feel like pulling his book off the shelf to check), but I'm pretty sure you don't want that unless you have multiple records per person per time point. hth, Jeph Michael I. Lichter wrote:I am having difficulties figuring out how to specify the randomeffects in -xtmixed- for my study design, and I haven't been able tofind anything helpful in the archives or the manual.My study is a standard cluster-randomized, two-condition,two-time-point trial with balanced allocation of clusters toconditions and only moderate variation in cluster size, with nostratification, crossing, matching, or anything else. Suppose I haveone record per time point per person with variables:c - study condition (control or intervention) t - time point (pretest or post-test) m - ID # for individual enrolled in trial g - group # y - study resultI am taking my guidance from David Murray's DESIGN AND ANALYSIS OFGROUP-RANDOMIZED TRIALS and trying to follow his example for what hecalls an "unadjusted time x condition analysis" for "nested cohortdesigns" (pp. 296-311). The model, with subscripts omitted, lookslike this: Y = mu + c + t + tc + G + M + TG + MT + e, where mu is thegrand mean, tc is the interaction effect t*c (same for TG and MT),and G, M, TG, and MT are random effects.Is any of these correct given the model?xtmixed y cond t tc || G: || M: || TG: || MT: xtmixed y cond t tc ||G: TG || M: MT xtmixed y cond t tc || G: M TG MTNone of the above converge successfully with my data, but thatdoesn't mean they're all wrong ... Obviously, I'm unclear on how thespecification of random effects works.FWIW, Murray provides the following SAS code (with my variable names;and "ddf = 4,4,4" is for a specific example):proc mixed info order=internal noclprint; class C G M T; model Y = C T C*T /ddf = 4,4,4 ddfm = res; repeated T /type = cs subject = M(G*C) r = 1 to 3 rcorr = 1 to 3; random G(C) TG(C); lsmeans C*T /slice=C slice=T c1 e; estimate `(I3 - I0)-(C3-C0)' C*T 1 -1 -1 1/cl e; run;I can run this in SAS, but the value of doing so is diminished by thefact that Murray's commands and annotations are about 10 years out ofdate; I'd rather do it in Stata if possible.Thanks.* * 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/

-- Michael I. Lichter, Ph.D. Research Assistant Professor & NRSA Fellow UB Department of Family Medicine / Primary Care Research Institute UB Clinical Center, 462 Grider Street, Buffalo, NY 14215 Office: CC 125 / Phone: 716-898-4751 / E-Mail: mlichter@buffalo.edu * * 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/

**References**:**st: specifying random effects in -xtmixed- for pretest/posttest clustered design***From:*"Michael I. Lichter" <mlichter@buffalo.edu>

**Re: st: specifying random effects in -xtmixed- for pretest/posttest clustered design***From:*Jeph Herrin <junk@spandrel.net>

- Prev by Date:
**Re: st: -outreg2- in Stata 10** - Next by Date:
**st: Decomposing cost variations between individual and higher level effects** - Previous by thread:
**Re: st: specifying random effects in -xtmixed- for pretest/posttest clustered design** - Next by thread:
**st: RE: specifying random effects in -xtmixed- for pretest/posttest clustered design** - Index(es):

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