Learn R Programming

robeth (version 2.7-8)

lywalg: W-algorithm for M-estimate of location

Description

Robust location estimate with simultaneous estimation of the scale parameter

Usage

lywalg(y, lambda, psp0 = psp(0), expsi = psi, exchi = chi, exrho = rho, 
       sigmai, tol = .dFvGet()$tlo, gam = .dFvGet()$gma, 
       isigma = .dFvGet()$isg, maxit = .dFvGet()$mxt, maxis = .dFvGet()$mxs, 
       nitmon = .dFvGet()$ntm)

Value

lambda

Final value of the location estimate

nit

Reached number of cycles

sigmaf

Final estimate of sigma

rs

The residual vector

Arguments

y

Vector containing the observations

lambda

Initial solution of the location parameter

psp0

Value of psp(0) (first derivative of the psi function)

expsi

User supplied psi function

exchi

User supplied chi function

exrho

User supplied rho function

sigmai

Initial estimate of the scale parameter

tol

Relative precision for the convergence criterion

gam

Relaxation factor. Set 0 < gam < 2.

isigma

If isigma<0, the value of sigma is not changed during the first iteration. If isigma=0, bypasss iteration on sigma (sigmaf=sigmai). If |isigma|>0, sigma is updated using the robeth function rysigm.

maxit

Maximum number of cycles

maxis

Maximum number of iterations for the scale step

nitmon

If nitmon>0 and the iteration counter is a multiple of nitmon, the current value of sigma, theta and delta are printed. If no iteration monitoring is required, set nitmon equal to 0.

Details

The .dFv variables for the default values must be created by a call to the dfvals() function of the robeth package. To see if this variable is available in your R session, type ls(all.names=TRUE). The parameters for psi, chi and rho functions must also be set by a preliminary call to the dfcomn function of the robeth package.

References

Marazzi A. (1993), Algorithm, Routines, and S functions for Robust Statistics, Wadsworth & Brooks/cole, Pacific Grove, California. p.30 and p.83 .