Try a different example:

set.seed(123)
N <- 24
k <- 6
x <- 1:N
f <- rep(rnorm(k, 0, 4), each = N/k)
e <- rnorm(N)
y <- x + f + e

fac <- gl(k, N/k)
library(lme4)
fm1 <- lmer(y ~ x + (1|fac)); fm1
fm0 <- lmer(y ~ x -1 + (1|fac)); fm0

plot(y, fitted(fm0))
abline(a = 0, b = 1, lty = 2, col = "blue")

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to