Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • mathematical formula of mixed models for repeated measures

    Dear Statalist users,
    I have a question about the mathematical formula of linear mixed models when we have pre-/-post test data.
    The data I work with come from a randomized controlled trial, where subjects were assigned to a control and treatment group and took had pre and post-test surveys. To analyze the effect of the treatment on the dependent variable (Y), I used the command 'mixed' on long-shaped data.

    Code:
     mixed Y Time##Treatment covariates || id:
    Now I am trying to convert it into a formula, yet I am not sure if the formula below captures the random effect. Unfortunately, it is in linear format; I could not figure out how to paste the subscripted version:

    Y_(ij= ) β_0 + β_1 G_i + β_2 T_j + β_3 G_i T_j + γX_i + ε_ij

    where
    Yij denotes the response variable scores for subject i at time j ;
    β0 is the mean response ;
    Gi refers to Group—Control (0) Treatment (1) ;
    Tj refers to time (pre-test (0) or post-test (1) ;
    Xi is the vector of control variables all measured in time 0 (pre-test survey).


    Thanks much in advance.
    Regards,
    Sule

  • #2
    Your equation is missing the term for the random intercept at the id level, and should read:

    Code:
    Y_(ij) =  β_0 + β_1 G_i + β_2 T_j + β_3 G_i T_j + γX_i + u_i + ε_ij

    Comment

    Working...
    X