Skip to content

Problems with function ranef in lme4

3 messages · Ben Bolker, Manuel Spínola

#
Dear list members,

I am trying the function ranef from package lme4 and I got the following 
error warning:

 > data(sleepstudy)
 > fm1 <- lmer(Reaction ~ Days + (Days|Subject), sleepstudy)
 > ranef(fm1)
Error en UseMethod("ranef") :
  no applicable method for 'ranef' applied to an object of class "mer"

What could be the problem?
Best,

Manuel
#
Manuel Sp?nola wrote:
My guess is that you have nlme loaded at the same time.

  search()
  detach("package:nlme")

  If that doesn't work, post the results of sessionInfo().
#
Thank you very much Ben.  That was the problem.

Manuel
Ben Bolker wrote: