powered by
Computes the element-wise adaptive Huber mean estimator.
huber_mean(x, tau)
A numeric scalar corresponding to the adaptive Huber mean estimator.
numeric
A numeric vector of observations.
A numeric scalar corresponding to the robustification parameter (larger than 0).
Haotian Xu
set.seed(123) y = rnorm(100) mean(y) huber_mean(y, 1.345)
Run the code above in your browser using DataLab