[R] problem with "nls" function

Walmes Zeviani walmeszeviani at hotmail.com
Tue Jan 26 04:12:54 CET 2010


I supose you are following the SAS formulation style. R has a different
formulation style, such as:

da <- expand.grid(A=factor(1:3), x=1:10)
da$y <- as.numeric(da$A)*da$x/(1.2+da$x)+rnorm(da$x, 0, 0.1)

m0 <- nls(y~Asym[A]*x/(Time[A]+x), data=da, start=list(Asym=c(1,2,3),
Time=c(1,1,1)))
summary(m0)

At your disposal.
Walmes.

-----
..oooO
..................................................................................................
..(....)... 0ooo...                              Walmes Zeviani
...\..(.....(.....)...     Master in Statistics and Agricultural
Experimentation
....\_)..... )../....       walmeszeviani at hotmail.com, Lavras - MG, Brasil
............
(_/............................................................................................
-- 
View this message in context: http://n4.nabble.com/problem-with-nls-function-tp1290020p1290034.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list