Re: [R] exponential fitting

2006-09-27 Thread Gabor Grothendieck
> # using this test data > set.seed(1) > x <- 1:20/20 > y <- exp(2 + 3 * x) + rnorm(20) > > # if its ok to fit logs so that its linear > exp(fitted(lm(log(y) ~ x))) 1 2 3 4 5 6 7 8 8.55615 9.94692 11.56376 13.44340 15.62857 18.

[R] exponential fitting

2006-09-27 Thread jessica . gervais
Hi, I would like to fit some experimental points by a exponential function. I ignore the parameters of this exponential and what I would like is to ask R to calculate the best fitting curve an the associated parameters (as the linear model function (lm) does for linear models). Is it possible