Last chance! 50% off unlimited learning
Sale ends in
wilcox.test
.HodgesLehmann(x, y = NULL, conf.level = NA, na.rm = FALSE)
wilcox.test
.
Note that in the two-sample case the estimator for the difference in location parameters does not estimate the difference in medians (a common misconception) but rather the median of the difference between a sample from x and a sample from y.
The confidence interval for the "pseudo median" is extracted from wilcox.test
(conf.int = TRUE
).wilcox.test
, median
, MedianCI
set.seed(1)
x <- rt(100, df = 3)
HodgesLehmann(x)
# same as
wilcox.test(x, conf.int = TRUE)$estimate
Run the code above in your browser using DataLab