[R] Extracting Variance components
Murray Jorgensen
maj at waikato.ac.nz
Mon Jun 5 06:29:48 CEST 2006
I can ask my question using and example from Chapter 1 of Pinheiro & Bates.
> # 1.4 An Analysis of Covariance Model
>
> OrthoFem <- Orthodont[ Orthodont$Sex == "Female", ]
> fm1OrthF <-
+ lme( distance ~ age, data = OrthoFem, random = ~ 1 | Subject )
> summary( fm1OrthF )
Linear mixed-effects model fit by REML
Data: OrthoFem
AIC BIC logLik
149.2183 156.169 -70.60916
Random effects:
Formula: ~1 | Subject
(Intercept) Residual
StdDev: 2.06847 0.7800331
[...etc...]
I can extract the estimate of the variance component \sigma (0.7800331) via
sigma <- fm1OrthF$sigma
How do I extract the other component \sigma_b (2.06847) ?
Cheers, Murray Jorgensen
--
Dr Murray Jorgensen http://www.stats.waikato.ac.nz/Staff/maj.html
Department of Statistics, University of Waikato, Hamilton, New Zealand
Email: maj at waikato.ac.nz Fax 7 838 4155
Phone +64 7 838 4773 wk Home +64 7 825 0441 Mobile 021 1395 862
More information about the R-help
mailing list