s-news
[Top] [All Lists]

Re: nlme, extract stand deviation value

To: "Li, Qishan" <qishan@email.arizona.edu>
Subject: Re: nlme, extract stand deviation value
From: Douglas Bates <bates@stat.wisc.edu>
Date: 27 Apr 2001 10:12:28 -0500
Cc: s-news@lists.biostat.wustl.edu
In-reply-to: <3AD79C980000B6B6@deimos.email.Arizona.EDU>
References: <3AD79C980000B6B6@deimos.email.Arizona.EDU>
User-agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7
"Li, Qishan" <qishan@email.arizona.edu> writes:

> I should be grateful for suggestions on how to do the following:
> 
> I am using Splus (nlme)  and I want to extract a parameter and use it later.
> The parameter value is 4.077946, which is the StdDev of Asym.
>                   > My_buffer<-  StdDev of Asym , the value is  4.077946
> 
> I do not know which function I should use. I tried
>                       >random.effects(fm2)
> but, it does not work.
> 
> Many thanks.
> 
> Qishan Li
> ---------------------------------------------
> >fm2 <- nlme(weight ~ SSlogis(Time, Asym, xmid, scal), data = Soybean,
>             fixed = Asym + xmid + scal ~ 1, random = pdDiag(Asym + xmid
> ~ 1),
>             start = c(18, 52, 7.5))
> 
> > fm2
> Nonlinear mixed-effects model fit by maximum likelihood
>   Model: weight ~ SSlogis(Time, Asym, xmid, scal)
>   Data: Soybean
>   Log-likelihood: -755.7323
>   Fixed: Asym + xmid + scal ~ 1
>      Asym     xmid    scal
>  18.96426 55.14188 8.55292
> 
> Random effects:
>  Formula: list(Asym ~ 1, xmid ~ 1)
>  Level: Plot
>  Structure: Diagonal
>             Asym    xmid Residual
> StdDev: 4.077946 2.52487   1.1924
> 
> Number of Observations: 412
> Number of Groups: 48

as.numeric(VarCorr(fm2)["Asym", "StdDev"])

<Prev in Thread] Current Thread [Next in Thread>