[R] How to get the parameters of nls(...) for later use

Peter Dalgaard p.dalgaard at biostat.ku.dk
Mon Nov 24 22:57:16 CET 2003


"Nancy Lo" <Nancy.Lo at noaa.gov> writes:

> Hi all,
> 
> I need to use the parameter estimates of nls() for further analysis. I
> know how to do in S+, e.g. nls(...)$parameters. In R, the
> attributes(nls(...)) does not have parameters, how would one get the
> parameter values out of nls()?
> Thanks in advance.

Same way as you really ought to do it in S-PLUS:

library(nls)
example(nls)

coef(Pur.wt)

or, if you insist on using the internals:  Pur.wt$m$getPars()


-- 
   O__  ---- Peter Dalgaard             Blegdamsvej 3  
  c/ /'_ --- Dept. of Biostatistics     2200 Cph. N   
 (*) \(*) -- University of Copenhagen   Denmark      Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk)             FAX: (+45) 35327907




More information about the R-help mailing list