A robust measure of dispersion. With M the sample median and
MAD the unscaled median absolute deviation, set
Y = (x - M) / (9 MAD) and a = 1 when |Y| < 1 and
0 otherwise. Then
\(zeta = sqrt(n) sqrt(sum(a (x - M)^2 (1 - Y^2)^4)) /
|sum(a (1 - Y^2)(1 - 5 Y^2))|\), and the biweight midvariance is
zeta^2.
Details
The MAD entering Y is the raw median absolute deviation,
not the rescaled MADN; the 9 is the tuning constant that decides
which points receive weight zero.
References
Wilcox, R. R. (2017). Modern Statistics for the Social and Behavioral Sciences: A Practical Introduction, 2nd edn. CRC Press, Box 2.1, equation (2.12), p.31.
Examples
Bimid(c(-1, 0, 1))$zeta
#> [1] 0.8373877
