[R-sig-ME] negative estimate from sd(resid(fit))

lancelot renaud.lancelot at cirad.fr
Wed Oct 5 18:16:50 CEST 2011


How do you access sigma ? My way is:

 > library(lme4)
[...]
 > fm <- lmer(Reaction ~ Days + (Days|Subject), data = sleepstudy)
 > attr(VarCorr(fm), "sc")
[1] 25.59182

All the best,

R

 > sessionInfo()
R version 2.13.2 (2011-09-30)
Platform: i386-pc-mingw32/i386 (32-bit)

locale:
[1] LC_COLLATE=French_France.1252  LC_CTYPE=French_France.1252 
LC_MONETARY=French_France.1252
[4] LC_NUMERIC=C                   LC_TIME=French_France.1252

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

other attached packages:
[1] lme4_0.999375-42   Matrix_0.9996875-4 lattice_0.19-34 
fortunes_1.4-2

loaded via a namespace (and not attached):
[1] grid_2.13.2   nlme_3.1-102  stats4_2.13.2 tools_2.13.2


Le 05/10/2011 10:14, Phil Smith a écrit :
> Hi lmer Club:
>
> I've got a model like lmer( y ~ x , 1|cluster).
>
> I'm permuting the cluster values 1000 times to obtain the nonparametric
> distribution of sigma under the null hypothesis that sigma = 0.
>
> I'm getting alot of negative values!!
>
> Am I doing something wrong, or what is going on there??
>
> Please reply directly to Phil.Smith.Duluth.GA at gmail.com  .... I'm not too
> good at understanding listserves.
>
> Thanks!
> Phil Smith
> CDC
>
> 	[[alternative HTML version deleted]]
>
> _______________________________________________
> R-sig-mixed-models at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>

-- 
Renaud Lancelot
EDENext Project, coordinator: http://www.edenext.eu/

CIRAD, UMR15, Campus International de Baillarguet TA A-DIR / B
F34398 Montpellier

Tel.  +33 4 67 59 37 17  -  Fax  +33 4 67 59 37 95
Secr. +33 4 67 59 37 37  - Cell. +33 6 77 52 08 69




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