Dear useRs,
I have the following plot:
pos - c(27/44, 11/32, 8/40, 4/42, 3/40, 4/40, 2/40)
tmin - c(15.8, 12.6, 10.5, 2.4, 5.2, 8.5, 7.9)
plot(tmin, pos)
I would like to fit an exponential curve to it.
How could I be able to do this?
Thanks in advance,
Rafael.
Hi Rafael,
Here is a suggestion:
# Data
pos - c(27/44, 11/32, 8/40, 4/42, 3/40, 4/40, 2/40)
tmin - c(15.8, 12.6, 10.5, 2.4, 5.2, 8.5, 7.9)
d - data.frame(pos, tmin)
# Non-linear model
fit - nls(pos ~ a*tmin^b,
data = d,
start = list(a = .1, b = .1),
2 matches
Mail list logo