wle.lm
is used to fit linear models via Weighted Likelihood, when the errors are iid from a normal distribution with null mean and unknown variance. The carriers are considered fixed. Note that this estimator is robust against the presence of bad leverage points too.
wle.lm(formula, data=list(), model=TRUE, x=FALSE, y=FALSE, boot=30, group, num.sol=1, raf="HD", smooth=0.031, tol=10^(-6), equal=10^(-3), max.iter=500, contrasts=NULL, verbose=FALSE)
wle.lm
is called from.TRUE
the corresponding components of the fit (the model frame, the model matrix, the
response.)raf="HD"
: Hellinger Distance RAF,
raf="NED"
: Negative Exponential Disparity RAF,
raf="SCHI2"
: Symmetric Chi-Squared Disparity RAF.
tol
).contrasts.arg
of model.matrix.default
.TRUE
warnings are printed.wle.lm
returns an object of class
"wle.lm"
.The function summary
is used to obtain and print a summary of the results.
The generic accessor functions coefficients
, residuals
and fitted.values
extract coefficients, residuals and fitted values returned by wle.lm
.The object returned by wle.lm
are:max.iter
iterations are reached.model=TRUE
a matrix with first column the dependent variable and the remain column the explanatory variables for the full model.x=TRUE
a matrix with the explanatory variables for the full model.y=TRUE
a vector with the dependent variable.Models for wle.lm
are specified symbolically. A typical model has the form response ~ terms
where response
is the (numeric) response vector and terms
is a series of terms which specifies a linear predictor for response
. A terms specification of the form first+second
indicates all the terms in first
together with all the terms in second
with duplicates removed. A specification of the form first:second
indicates the the set of terms obtained by taking the interactions of all terms in first
with all terms in second
. The specification first*second
indicates the cross of first
and second
. This is the same as first+second+first:second
.
Agostinelli, C., Markatou, M., (1998) A one-step robust estimator for regression based on the weighted likelihood reweighting scheme, Statistics \& Probability Letters, Vol. 37, n. 4, 341-350.
Agostinelli, C., (1998) Verosimiglianza pesata nel modello di regressione lineare, XXXIX Riunione scientifica della Societ\`a Italiana di Statistica, Sorrento 1998.
library(wle)
# You can find this data set in:
# Hawkins, D.M., Bradu, D., and Kass, G.V. (1984).
# Location of several outliers in multiple regression data using
# elemental sets. Technometrics, 26, 197-208.
#
data(artificial)
result <- wle.lm(y.artificial~x.artificial,boot=40,num.sol=3)
summary(result)
plot(result)
Run the code above in your browser using DataLab