Learn R Programming

asbio (version 1.9-7)

r.bw: Biweight midvariance, and biweight midcorrelation.

Description

Calculates biweight midvariance if one variable is given and biweight midvariances, midcovariance and midcorrelation if two variables are given. Biweight midcorrelation is a robust alternative to Pearson's r.

Usage

r.bw(X, Y=NULL)

Value

Returns the biweight variance if one variable is given, and the biweight midvariances, midcovariance and midcorrelation if two variables are given.

Arguments

X

A numeric vector

Y

An optional second numeric variable.

Author

Ken Aho

Details

Biweight statistics are robust to violations of normality. Like the sample median the sample midvariance has a breakdown point of approximately 0.5. The triefficiency of the biweight midvariance was the highest for any of the 150 measures of scale compared by Lax (1985).

References

Lax, D. A. (1985) Robust estimators of scale: finite sample performance in long-tailed symmetric distributions. Journal of the American Statistical Association, 80 736-741.

Wilcox, R. R. (2005) Introduction to Robust Estimation and Hypothesis Testing, Second Edition. Elsevier, Burlington, MA.

See Also

cor, r.pb

Examples

Run this code
x<-rnorm(100)
y<-rnorm(100)
r.bw(x,y)

Run the code above in your browser using DataLab