Learn R Programming

numOSL (version 1.6)

fitGrowth: Fitting a growth curve

Description

Fitting a growth curve using the Levenberg-Marquardt algorithm.

Usage

fitGrowth(Curvedata, model = c("line","exp","lexp","dexp"), 
          origin = FALSE, nstart = 100, upb = 0.5, plot = TRUE)

Arguments

Curvedata
matrix(required): three columns, i.e., regenerative doses, standardised OSL signals, and standard errors of standardised OSL signals
model
character(with default): a fitting model, default model="line", see details
origin
logical(optional): force the fitting to pass the origin or not
nstart
numeric(with default): the maximum number of attempts of initializing the non-linear growth curve fitting, see details
upb
numeric(with default): the upper limit on b value (the reciprocal of the saturating dose), initial b value is generated uniformly from the space (0,upb), see details
plot
logical(with default): draw a plot or not

Value

  • Return an list that contains following elements:
  • LMparsparameters and standard errors of the growth curve
  • valuethe minimized chi-square value of the fitted growth curve
  • fit.valueobservations and fitted values

Details

For fitting a growth curve, four models are available: (1) "line": a linear model, y=a*x+b; (2) "exp": an exponential model, y=a*[1-exp(-b*x)]+c; (3) "lexp": an exponential plus linear model, y=a*[1-exp(-b*x)]+c*x+d; (4) "dexp": an double exponential model, y=a*[1-exp(-b*x)]+c*[1-exp(-d*x)]+e. The weighted curve fitting is performed using the Levenberg-Marquardt algorithm by J.J. More (available at http://ftp.netlib.org/minpack). When fitting a non-linear model, a series of b(d) values (i.e., the reciprocal of the saturating dose) are initialized randomly with a uniform distribution in the space (0,upb), then other parameters are estimated with a Linear Algebra method. For a growth curve that shows high saturating dose, it is more reasonable to use a smaller upb value. For example, a double saturating exponential model with a upb value less than 0.05 or 0.01 usually works better. The fitting process will be performed repeatedly with nstart times to find an optimal estimate. User is advised to set argument plot to be TRUE if possible in order to see if the fitted growth curve is correct.

References

More JJ, 1978. "The Levenberg-Marquardt algorithm: implementation and theory," in Lecture Notes in Mathematics: Numerical Analysis, Springer-Verlag: Berlin. 105-116.

See Also

analyst; calED; fastED

Examples

Run this code
data(Signaldata) 
 dat<-analyst(Signaldata[[1]], Redose=c(80,160,240,320,0,80)*0.13, 
              model="line", origin=TRUE, plot=FALSE, nsim=100)
 fitGrowth(dat$Curvedata, model="exp", origin=FALSE, plot=TRUE)

Run the code above in your browser using DataLab