Skip to content
Prev 10524 / 20628 Next

lme: random effects for replicated growth curves

Hi Ben,

Thanks for your suggestion, I tried to play around with the gls function, but didn't manage get an adequate model so far.
I am looking now at alternatives to mixed-effect models, such as growth mixture models.

I'll keep you posted if I find a proper solution.


-----Original Message-----
From: Ben Bolker [mailto:bbolker at gmail.com] 
Sent: Tuesday, August 20, 2013 4:54 PM
To: Adrien Combaz; r-sig-mixed-models at r-project.org
Subject: Re: [R-sig-ME] lme: random effects for replicated growth curves

[cc'ing back to r-sig-mixed-models ]

  I'm still not 100% sure what the problem is, and I don't know if I have time to dig through in detail, but here's an example that _might_ help -- if you want to use a grouped correlation structure without incorporating random effects ...


 d <- data.frame(x=1:1000,
   f=rep(1:50,each=20),
   y=rnorm(1000),time=rep(1:20,50))

lme(y~x,correlation=corAR1(form=~time|f),random=~1|f,data=d)
gls(y~x,correlation=corAR1(form=~time|f),data=d)  ## without RE
On 13-08-20 07:48 AM, Adrien Combaz wrote: