Hodges-Lehmann Estimator (Location Shift)

Estimate and confidence interval of the location shift η₁−η₂ of two independent samples, matching the Mann-Whitney U test.

Statusvalidated
Version1.0.0
Minitab equivalentStat > Nonparametrics > Mann-Whitney (point estimate and CI for η1 − η2)

Description

The Hodges-Lehmann estimator is the median of all n₁·n₂ pairwise differences xᵢ − yⱼ. The confidence interval consists of two order statistics of these differences; the index K comes exactly from the U distribution (n₁, n₂ < 50, no ties) or from the normal approximation with tie correction. Because K is an integer, the achieved confidence is reported. The estimator describes the shift, not the difference of medians; the two coincide only when the distributions have the same shape. Without ties (exact), '0 in the CI iff p ≥ α' holds. The only exception: when K is clamped to 1 and P(U ≤ 0) is exactly α/2, p = α, yet the CI [min d, max d] can still exclude 0 (same as R). With ties the relation holds only approximately.

Formulas

Δ̂
Hodges-Lehmann estimator: median of all n₁·n₂ pairwise differences
KI
Confidence interval as order statistics of the sorted differences d
K (exakt)
Index K from the exact U distribution (n₁, n₂ < 50, no ties), as R qwilcox: smallest u with P(U ≤ u) ≥ α/2, so P(U ≤ K−1) < α/2; equality P(U ≤ u) = α/2 is not counted. K < 1 is clamped to 1
K (Normalapproximation)
Index K from the normal approximation with tie correction (σ_U as in the Mann-Whitney U test)

Assumptions

  • Samples are independent
  • Observations are continuous (at least ordinal)
  • Both distributions have the same shape (shift model)

Limitations

  • Achieved confidence deviates from the target because K is an integer; for very small samples (e.g. 2 vs. 2) it falls noticeably below it
  • With ties, the interval is only approximately consistent with the p-value of the Mann-Whitney test
  • Edge case: when K is clamped to 1 and P(U ≤ 0) is exactly α/2, p = α, yet the CI [min d, max d] can exclude 0 (same as R)

References

  • Hodges, J. L. & Lehmann, E. L. (1963), Estimates of location based on rank tests, Annals of Mathematical Statistics 34(2), 598–611
  • Lehmann, E. L. (1975), Nonparametrics: Statistical Methods Based on Ranks, Holden-Day
  • Hollander, M. & Wolfe, D. A. (2013), Nonparametric Statistical Methods, 3rd Ed.