Skip to content
Prev 174645 / 398506 Next

Extracting SD of random effects from lme object

On Mon, Mar 23, 2009 at 11:26 AM, Ben Domingue <ben.domingue at gmail.com> wrote:
To get the covariance matrix of the random effects:
Random effects variance covariance matrix
            (Intercept)       age
(Intercept)     5.41510 -0.321060
age            -0.32106  0.051269
  Standard Deviations: 2.327 0.22643


One way to extract the standard deviations shown by the print method above is:
(Intercept)         age
  2.3270339   0.2264276
Warning message:
In sqrt(getVarCov(fm1)) : NaNs produced


And to get the estimate of the error standard deviation:
[1] 1.31004


hth,

Kingsford Jones