dfrmest.NLM: Derivative free MM-estimate

Description Usage Arguments Details Value Note Author(s) References See Also Examples

View source: R/dfrmest_NLM.R

Description

MM-estimate of a nonlinear function, Using Mixture of Newton and Levenberg-Marquardt method. Parameters estimates by robust MM-estimate by minimizing the sum of robust rho function. Required derivatives such as gradient and hessian are computed numericaly by the loss function dfr.robloss

Usage

1
2
3
dfrmest.NLM(formula, data, start = getInitial(formula, data), robfunc, control =
nlr.control(tolerance = 0.01, minlanda = 1/2^25,maxiter = 25 * length(start)), vm = NULL, 
rm = NULL, ...)

Arguments

formula

nl.form object of the nonlinear function model. See nl.form object.

data

list of data with the response and predictor as name of variable. In heterogeneous case if it include response variable values of heterogenous variance function it asume variance function is function of predictor H(x_i,τ), otherwise it assume is a function of predictor H(f(x_i,θ),τ).

start

list of starting value parameter, name of parameters must be represented as names of variable in the list.

robfunc

nl.form object of robust function used for downgrading.

control

nlr.control object, include tolerance, maxiter,... see nlr.control.

vm

optional covariance matrix of residuals, used for nonlinear generalized M-estimate.

rm

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))).

...

any other argument passed to formula, robfnc, or optimization function.

Details

This function is mixture of Levenberg Marquardt, Newton and Steepest descent, but using numerical derivatives. It is used to minimize the robust loss function using ρ function.

Due to wrong effect of outlier in creating singularity in hessian matrix the levenberg Marquardt is used to remedy the effect. Morover for fast convergence when hessian is non singular Newton with Steepest descent is applied.

Value

result is object of nl.fitt.rob (nonlinear fitt robust) for homogeneous variance, and nl.fitt.rgn for heterogeneous and autocorrelated error (nonlinear fitt robust generalized), see nl.fitt.rgn object detail.

parameters

nonlinear regression parameter estimate of θ.

correlation

of fited model.

form

nl.form object of called nonlinear regression model.

response

computed response.

predictor

computed (right side of formula) at estimated parameter with gradient and hessian attributes.

curvature

list of curvatures, see curvature function.

history

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.

method

fittmethod object of method used for fitt.

data

list of called data.

sourcefnc

Object of class "callorNULL" source function called for fitt.

Fault

Fault object of error, if no error Fault number = 0 will return back.

htheta

robust loss value including gradient and hessain attributes.

rho

computed robust rho function, including gradient and hessain attributes.

ri

estimated residuals, including gradient and hessain attributes.

curvrob

curvature

robform

nl.form object of robust loss rho function.

if vm is not NULL the nl.fitt.rgn include following extra slots:

vm

covariance matrix, diagonal of variance model predicted values.

rm

cholesky decomposition of vm.

gresponse

transformed of response by rm, include gradinet and hessian attributes.

gpredictor

transformed of predictor by rm, include gradinet and hessian attributes.

Note

starting values start it must contains initial value for 'sigma'. This function is called from nlr with derivfree=TRUE and method="MM" in control argument, it is more effient to be called from nlr not directly by user.

Author(s)

Hossein Riazoshams, Jan 2010. Email: riazihosein@gmail.com URL http://www.riazoshams.com/nlr/

References

Riazoshams H, Midi H, and Ghilagaber G, 2018,. Robust Nonlinear Regression, with Application using R, Joh Wiley and Sons.

See Also

dfr.robloss, nlmest.LM, nlmest.WF, nl.form, nl.fitt.rob, nl.fitt.rgn, nlr.control

Examples

1
2
3
4
5
6
7
8
9
datalist=list(xr=ntp$dm.k,yr=ntp$cm.k)
ntpstart=list(p1=.12,p2=6,p3=1,p4=33)
ntpstarttau=list(tau1=-.66,tau2=2,tau3=.04)
fittnml <- dfrmest.NLM(formula=nlrobj1[[16]], data = datalist, start=ntpstart,
robscale = TRUE, robfunc = nl.robfuncs[["huber"]],control=
nlr.control(tolerance=1e-4,trace=TRUE))
fittnml$parameters
## The function is currently defined as
"dfrmest.NLM"

nlr documentation built on July 31, 2019, 5:09 p.m.

Related to dfrmest.NLM in nlr...