Andreas Löffler's implementation of the exact p-values calculations for the Mann-Whitney U test

1 · Andrey Akinshin · Jan. 23, 2024, 12:33 p.m.
Mann-Whitney is one of the most popular non-parametric statistical tests. Unfortunately, most test implementations in statistical packages are far from perfect. The exact p-value calculation is time-consuming and can be impractical for large samples. Therefore, most implementations automatically switch to the asymptotic approximation, which can be quite inaccurate. Indeed, the classic normal approximation could produce enormous errors. Thanks to the Edgeworth expansion, the accuracy can be impro...