[R-sig-ME] gls() vs. lmer() random effects estimation

Maarten Jung Maarten.Jung at mailbox.tu-dresden.de
Tue Jan 30 07:48:04 CET 2018

Dear list,

Let x be a factor with k levels.
Why can m1 be estimated with only one data point per level of x for each
I know that the random slope variance is confounded with the residual
variance in m2 and thus m2 cannot be estimated in this case.
But how can m1 overcome this limitation whereas m3 (which I think is
equivalent to m4) is the maximal linear mixed model that can be estimated
with lmer? And is there a way to achieve the same with lmer?

m1 <- gls(y ~ x, correlation = corSymm(form = ~1|subject), data = d)
m2 <- lmer(y ~ x + (x|subject), data = d)
m3 <- lmer(y ~ x + (1|subject), data = d)
m4 <- gls(y ~ x, correlation = corCompSymm(form = ~1|subject), data = d)


	[[alternative HTML version deleted]]

More information about the R-sig-mixed-models mailing list