[R] Sigmoidal fitting

Cressoni, Massimo (NIH/NHLBI) [F] cressonim at nhlbi.nih.gov
Sat Mar 3 22:30:17 CET 2007


I am trying to write a function that fits a sigmoid given a X and Y vector guessing the start parameters.
I use nls. What I did (enclosed) seems to work well with many data points but if I want to fit small
vectors like :

pressure <- c(5,15,9,35,45)
gas <- c(1000,2000,3000,4000,5000)

it do not work. The help page says that it do no not work on zero residual data.

Massimo Cressoni



More information about the R-help mailing list