Hi, Luca,

yes, I updated R and lme4 yesterday. I just re-installed R and ranef() 
is working again.
I should say that I am using a MacBook Pro with OS X 10.6.4.

thanks,

Gustavo


On 10-07-28 3:00 PM, Luca Borger wrote:
> Hello,
>
> are you using updated versions for lme4, Matrix, R? It works on my 
> machine (Windows, see below):
>
> (gm1 <- glmer(cbind(incidence, size - incidence) ~ period + (1 | herd),
> +               family = binomial, data = cbpp))
>
>> ranef(gm1)
> $herd
>   (Intercept)
> 1   0.59002543
> 2  -0.29889417
> 3   0.40626540
> 4   0.03928257
> 5  -0.19001102
> 6  -0.40026000
> 7   0.88940374
> 8   0.59937372
> 9  -0.23764977
> 10 -0.54092635
> 11 -0.08462816
> 12 -0.06481190
> 13 -0.68991231
> 14  0.97071999
> 15 -0.53046901
>
>>
>
>
>> fm3 <- lmer(diameter ~ (1|plate) + (1|sample), Penicillin)
>> ranef(fm3)
> $plate
>  (Intercept)
> a  0.80454705
> b  0.80454705
> c  0.18167191
> d  0.33739070
> e  0.02595313
> f -0.44120322
> g -1.37551593
> h  0.80454705
> i -0.75264079
> j -0.75264079
> k  0.96026583
> l  0.49310948
> m  1.42742219
> n  0.49310948
> o  0.96026583
> p  0.02595313
> q -0.28548444
> r -0.28548444
> s -1.37551593
> t  0.96026583
> u -0.90835957
> v -0.28548444
> w -0.59692201
> x -1.21979714
>
> $sample
>  (Intercept)
> A  2.18724529
> B -1.01056270
> C  1.93806545
> D -0.09690327
> E -0.01384332
> F -3.00400144
>
>>
>
>
>> sessionInfo()
> R version 2.11.1 (2010-05-31)
> i386-pc-mingw32
>
> locale:
> [1] LC_COLLATE=English_United Kingdom.1252  LC_CTYPE=English_United 
> Kingdom.1252    LC_MONETARY=English_United Kingdom.1252 LC_NUMERIC=C
> [5] LC_TIME=English_United Kingdom.1252
>
> attached base packages:
> [1] stats     graphics  grDevices utils     datasets  methods   base
>
> other attached packages:
> [1] lme4_0.999375-34   Matrix_0.999375-42 lattice_0.18-8
>
> loaded via a namespace (and not attached):
> [1] grid_2.11.1   nlme_3.1-96   stats4_2.11.1 tools_2.11.1
>>
>
>
> HTH
>
> Cheers,
>
> Luca
>
>
> ----- Original Message ----- From: "Gustavo Betini" <betinig@uoguelph.ca>
> To: <r-sig-mixed-models@r-project.org>
> Sent: Wednesday, July 28, 2010 11:50 AM
> Subject: [R-sig-ME] Error in UseMethod("ranef")
>
>
>> Hi, all,
>>
>> yesterday I ran a GLMM with the glmer function from the lme4 package,
>> and extracted the modes of the random effects using ranef(model). This
>> morning I tried to do the same and got the following error:
>>
>> Error in UseMethod("ranef") :
>>   no applicable method for 'ranef' applied to an object of class "mer"
>>
>> I tried the example from the R documentation,
>>
>> fm3 <- lmer(diameter ~ (1|plate) + (1|sample), Penicillin)
>> ranef(fm1)
>>
>> and got the same error. It seems that I am missing something. Any clue?
>>
>> Thanks,
>>
>> Gustavo S. Betini
>>
>>
>>
>> [[alternative HTML version deleted]]
>>
>> _______________________________________________
>> R-sig-mixed-models@r-project.org mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>>
>
> _______________________________________________
> R-sig-mixed-models@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models

	[[alternative HTML version deleted]]


