Least Square estimate of a nonlinear function, Using Nelder Mead derivative free optimization method.
nlsnm(formula, data, start = getInitial(formula, data), delta = NULL,
control = nlr.control(tolerance = 1e-04,
maxiter = 100 * length(start)), vm = NULL, rm = NULL, ...)
nl.form object of the nonlinear function model. See nl.form
object.
list of data with the response and predictor as name of variable.
list of starting value parameter, name of parameters must be represented as names of variable in the list.
nlr.control object, include tolerance, maxiter,... see nlr.control
.
NULL, optional covariance matrix of residuals, used for nonlinear generalized M-estimate.
optional correlation matrix, used for nonlinear generalized M-estimate. rm is correlation matrix of vm, thus only vm is enough to be given. It can be given by user also but not necessary automatically will be calculated by argument eiginv(t(chol(vm))).
increament of Nelder Mead method, default will be calculated 10% of parameter values, in the case of nonconvergence it can be modified manually to acheive convergence.
any other argument passed to formula, robfnc, or optimization function.
result is object of nl.fitt
(nonlinear fitt robust) for homogeneous variance, and nl.fitt.gn
for generalized fitt when covariance or correlation matrix is given.
nonlinear regression parameter estimate of \(\theta\).
of fited model.
nl.form
object of called nonlinear regression model.
computed response.
computed (right side of formula) at estimated parameter with gradient and hessian attributes.
list of curvatures, see curvature
function.
matrix of convergence history, collumns include: convergence index, parameters, minimized objective function, convergence criterion values, or other values. These values will be used in plot
function in ploting history.
fittmethod
object of method used for fitt.
list of called data.
Object of class "callorNULL"
source function called for fitt.
Fault
object of error, if no error Fault number = 0 will return back.
covariance matrix, diagonal of variance model predicted values.
cholesky decomposition of vm.
transformed of response by rm, include gradinet and hessian attributes.
transformed of predictor by rm, include gradinet and hessian attributes.
Nelder Mead is derivative free optimization method. It is used to minimize the square loss function. This method is very slow and sugest to use with a large maximum number of iterations.
Statistical Computing with R, Maria L. Rizzo, 2008, Chopman & Hall/CRC
# NOT RUN {
## The function is currently defined as
"nlsnm"
# }
Run the code above in your browser using DataLab