1
$\begingroup$

I’m hoping to get some guidance in specifying a mixed model using the lme4 package in R.

The study is quite straightforward. It’s a repeated measures design with pre/post measurements on the variable of interest where half of the participants received the treatment (a physical therapy program) and the other half did not. The research was carried out in groups at 8 different hospitals. Because the research was carried out in groups, I’m treating the data as multilevel with Time at level 1, Individual at level 2, and Group at level 3. The structure of the data can be seen below:

'data.frame':   1856 obs. of  6 variables:
 $ ID           : num  1 1 2 2 3 3 4 4 5 5 ...
 $ Group        : Factor w/ 8 levels "Richmond",..: 1 1 1 1 1 1 1 1 1 1 ...
 $ Age          : num  12 12 14 14 13 13 18 18 16 16 ...
 $ Treatment    : Factor w/ 2 levels "No","Yes": 2 2 2 2 2 2 2 2 2 2 ...
 $ Time         : Factor w/ 2 levels "Pre","Post": 1 2 1 2 1 2 1 2 1 2 ...
 $ DV           : num  4 7 4 3 4 8 8 9 5 5 ...

I’m trying to answer the following questions:

  1. Was there an improvement in the DV over time?
  2. Did participants in the treatment program improve more than those in the control group?

    I’m not expecting any, but I’d also like to know:

  3. If there are differences in the DV attributable to age.

  4. If there are differences in the DV attributable to the location (group).

To that end I have specified the following model treating Time, Treatment and Age as fixed effects and Group as a random effect.

lmer(DV ~ Time + Treatment + Time*Treatment + Age + (1 | ID) + (1 | Group), 
     data = TLHB.data, REML = FALSE)

However, I’m not sure that this model accounts for the fact that participants were nested in groups so am looking for guidance that my approach so far seems reasonable given my research questions and how to properly specify that the participants within each group were not necessarily independent.

$\endgroup$
  • $\begingroup$ As a start: Age should most probably be a fixed effect. And a random patient effect is missing to account for the repeated measures structure. Question: why not modelling absolute or relative changes in the DV? $\endgroup$ – Michael M Apr 23 '14 at 15:27
  • 1
    $\begingroup$ @MichaelMayer - Thanks very much for your comment- I've edited the model in my post to reflect your feedback. I'm still unsure if the two random effects (ID & Group) are sufficient to capture the nested structure of the data. As to your question, are you asking why I didn't use the difference between Time 1 and Time 2 scores as my DV and Time 1 as a covariate as opposed to including both in an RM model? $\endgroup$ – Jay Apr 24 '14 at 3:25
  • $\begingroup$ Yes, to get rid of one within subject factor. (The fixed time and treatment main effects are already implied by the asterisk sign in the interaction. So you can drop them.) $\endgroup$ – Michael M Apr 24 '14 at 6:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.