I assume you mean the following:

chemYield <-
function(a, x)(a[1]+(a[3]-a[2])/(1+exp(-a[2]*(x-a[4]))

If you want to estimate parameters a[1:4] from data on pairs of (x, y=chemYield), create a data.frame(x, y), and estimate the parameter vector "a" using "nls".

If you have trouble getting "nls" to converge, I would plot the data and make a serious effort to get good starting values for "a" from the plot. If I still have trouble, I'd try "optim", then feed the output from "optim" into "nls".

I seem to recall having seen problems like this discussed in Bates and Watts (1988) Nonlinear Regression Analysis and Its Applications (Wiley). I don't have the book in hand at the moment, so I can't give you a page reference, but they discuss problems of this nature. Bates was a pioneer in developing measures of intrinsic vs. parameter effects curvature. Bates and Watts studied many published data sets and found that in nearly all cases, the parameter effects curvature was at least an order of magnitude larger than the intrinsic curvature. That means that numerical difficulties can often (usually?) be improved by trying different parameterizations for the same problem.

The function "nls" and similar functions are described among other places in Venables and Ripley (2002) Modern Applied Statistics with S, 4th ed. (Springer, ch. 8).

hope this helps. spencer graves

Andrea Calandra wrote:
HI

I'm a student in chemical engineering, and i have
to implement an algoritm about FIVE PARAMETERS
INTERPOLATION for a calibration curve (dose, optical density)

y = a + (c - a) /(1+ e[-b(x-m])


where
x = ln(analyte dose + 1)
y = the optical absorbance data
a = the curves top asymptote
b = the slope of the curve
c = the curves bottom asymptote
m = the curve X intercept

Have you never seen this formula, because i don't fine information or
lecterature about solution of this!!!

Can i help me

Hi Mr. Calandra

______________________________________________
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help

______________________________________________ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help

Reply via email to