nlsr: nlsr function

nlsrR Documentation

nlsr function

Description

Provides class nls solution to a nonlinear least squares solution using the Nash Marquardt tools.

Usage

  nlsr(formula = NULL,  data = NULL,  start = NULL,  control = NULL,
    trace = FALSE, subset = NULL, lower = -Inf, upper = Inf,  weights = NULL,
    ...)

Arguments

formula

The modeling formula. Looks like 'y~b1/(1+b2*exp(-b3*T))'

data

a data frame containing data for variables used in the formula that are NOT the parameters. This data may also be defined in the parent frame i.e., 'global' to this function

start

MUST be a named vector with all elements present e.g., start=c(b1=200, b2=50, b3=0.3)

control

a list of control parameters. See nlsr.control().

trace

TRUE for console output during execution (default FALSE)

subset

an optional vector specifying a subset of observations to be used in the fitting process. NOT used currently by nlxb() or nlfb() and will throw an error if present and not NULL.

lower

a vector of lower bounds on the parameters. If a single number, this will be applied to all parameters Default -Inf.

upper

a vector of upper bounds on the parameters. If a single number, this will be applied to all parameters. Default Inf.

weights

A vector of fixed weights. The objective function that will be minimized is the sum of squares where each residual is multiplied by the square root of the corresponding weight. Default NULL implies unit weights.

...

additional data needed to evaluate the modeling functions

Value

A solution object of type nls


nlsr documentation built on Sept. 8, 2023, 5:48 p.m.