[R] Random effects and lme4
wmh
wmhirst at hotmail.com
Thu Jul 3 19:33:27 CEST 2008
I'm running some multi-level binomial models with lme4 and have a question
regarding the estimated random effects.
Suppose I have nested data e.g. clinic and then patient within clinic. The
standard deviations of the random effects at each level are roughly equal in
a model for real life data. Attention then turns to examining the individual
random effects at each level. I'm extracting these using ranef(). As I
understand it one expects a certain amount of "shrinkage" here but what I'm
finding is that the standard deviations of the estimated intercepts are
smaller then expected and in particular are much smaller at the patient
within clinic level. Is this normal or am I interpreting the estimated
intercepts incorrectly?
An example from some simulated data:
Model:
Logit(p)=a+bx+c+d
Where c is the level 1 random effect - clinic - N(0,sd=sigma1)
Where d is the level 2 random effect - patient within clinic -
N(0,sd=sigma2).
Here a=-0.8,b=1,sigma1=0.3,sigma2=0.3
I'm simulating for 50 clinics each with 25 patients and 5 visits per patient
(a total of 6250 observations per simulation). There are 200 runs.
The results - mean - from 200 runs
mean(a)= -0.80
mean(b)= 1.00
mean(sigma1) = 0.29
mean(sigma2) = 0.26
However the sd of the estimated intercepts extracted using ranef at each
level are:
mean(Level 1 intercepts) = 0.23
mean(Level 2 intercepts) = 0.07
I'd expect the level 2 intercepts to be produced with more variation than
the mean value of 0.07 from this simulation.
--
View this message in context: http://www.nabble.com/Random-effects-and-lme4-tp18264554p18264554.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list