Learn R Programming

robustreg (version 0.1-8)

robustRegBS: Robust Regression Function using Bisquare Psi Function

Description

Using iteratively reweighted least squares (IRLS), the function calculates the optimal weights to perform m-estimator or bounded influence regression. Returns robust beta estimates and prints robust ANOVA table.

Usage

robustRegBS(formula,data,tune=4.685,m=TRUE,max.it=1000,tol=1e-6,anova.table=FALSE)

Arguments

formula
Model
data
A data frame containing the variables in the model.
tune
Tuning Constant. Default value of 4.685 is 95% asymptotically efficient against outliers
m
If TRUE, calculates m estimates of beta. If FALSE, calculates bounded influence estimates of beta
max.it
Maximum number of iterations to achieve convergence in IRLS algorithm
tol
Tolerance level in determining convergence
anova.table
If TRUE, prints robust ANOVA table

Details

M-estimates of beta should be used when evaluating least squares estimates of beta and diagnostics show outliers. Least squares estimates of beta should be used as starting points to achieve convergence.

Bounded influence estimates of beta should be used when evaluating least squares estimates of beta and diagnostics show large values of the "Hat Matrix" diagonals and outliers.

References

Tukey,

Birch, Robust F-Test, 1983

See Also

robustRegH()

Examples

Run this code
data(stackloss)
robustRegBS(stack.loss~Air.Flow+Water.Temp,data=stackloss)

#If X matrix contained large values of H matrix (high influence points)
robustRegBS(stack.loss~Air.Flow+Water.Temp,data=stackloss,m=FALSE)

Run the code above in your browser using DataLab