[R] treatment effects with lme (repeated measurements)

Steffen Fleischer steffen.fleischer at medizin.uni-halle.de
Fri Dec 3 09:12:49 CET 2010


Dear,

I want to analyze an outcome in an RCT using lme but I am not sure that I have chosen the right way for the model.
We measured the outcome three times repeatedly in the same patient. One time before intervention and two times after intervention. I wanted to adjust for the correlated data in the repeated measurement and baseline differences in the variable in order to get the treatment effect.

Here the model:
lme(outcome~treatment*time+baseline; random=~1|id)

for the data structure:

id   time  outcome  baseline  treatment
1     1         10           5             1
1     2         12           5             1
2     1............
.
.
.

alternatively I could use 3 rows per participant, omitting baseline as a variable as it would be included in "outcome" and "time" then.
The model then would be:
lme(outcome~treatment*time; random=~1|id)


I am not sure which way is better/right or if there is a third alternative for this problem.

Thanks in advance

Steffen Fleischer



More information about the R-help mailing list