Gives a bisquare M-estimate of regression for one explanatory variable
with intercept.
USAGE:
rbiwt(x, y, start=lsfit(x,y), k=6, tol=.001, iter=20)
REQUIRED ARGUMENTS:
x
vector of observations on the explanatory variable.
Missing values (
NAs) are not allowed.
y
vector of observations on the response variable.
Missing values (
NAs) are not allowed.
OPTIONAL ARGUMENTS:
start
vector giving starting values of intercept and slope.
The default is to use the least squares coefficients.
k
biweight scale parameter.
tol
convergence tolerance.
iter
maximum number of iterations.
VALUE:
list containing components
coef
vector giving intercept and slope.
resid
vector like
y giving residuals from fit.
wt
vector giving weights used in final weighted least-squares
step.
DETAILS:
A maximum of
iter iterations using the bisquare weighting function with
tuning constant
k are performed.
Convergence is achieved if the absolute value of the difference between the
old and new coefficients is less in both cases than the absolute value of
the coefficients times
tol.
REFERENCES:
Coleman, D., Holland, P., Kaden, N., Klema, V., and Peters, S. C., (1980).
A System of Subroutines for Iteratively Re-Weighted Least-Squares Computations.
ACM Transactions on Mathematical Software6, 327-336.
SEE ALSO:
,
(which generalizes
to multiple regression and has a choice of weighting functions).