Home / Tools / Nonparametric Test Calculator

Nonparametric Test Calculator

Rank-based tests compare groups without assuming a normal distribution, so they work on skewed data, small samples, ordinal ratings and data with outliers. Pick the question you are asking, paste your numbers, and this tool runs the right test and reports the statistic, exact p-value, effect size and a Hodges-Lehmann confidence interval. Everything runs in your browser.

Your data
Examples:

Alternative
Significance α
Compare to μ
 

 

 

Statistic
-
p-value
-
Effect size
-
Estimate
-
Decision
-

 

Inference

 
How this is computed
1
2
3
4
The same test in R

  

No data leaves your browser Verified against R's wilcox.test(), kruskal.test() and binom.test() Free, no sign-up

The four rank-based tests

Each test answers a different question. Match the shape of your data to the right one; the tool switches automatically when you pick a mode above.

Mann-Whitney U

Also called the Wilcoxon rank-sum test. Compares two independent groups, such as treatment versus control, by pooling and ranking all the values. It asks whether one group tends to score higher than the other.

two independent groups
Wilcoxon signed-rank

Compares two paired measurements (before versus after on the same subjects) or one sample against a reference value. It ranks the absolute differences and sums the ranks of the positive ones.

paired or one-sample
Kruskal-Wallis

The rank-based analogue of one-way ANOVA. Compares three or more independent groups at once and returns an H statistic with a chi-square p-value. A significant result says at least one group differs.

three or more groups
Sign test

The most robust option: it uses only the direction of each paired difference, not its size. It counts how many differences are positive and tests that against a coin flip with an exact binomial test.

direction of change

Which test, and how it is computed

All four are computed the way base R computes them. The tool uses the exact distribution for small, tie-free samples and the normal approximation otherwise, then pins those choices in the R code so it reproduces the number on screen.

Your dataTestR callReports
Two independent groupsMann-Whitney Uwilcox.test(a, b)U, p, rank-biserial r, Hodges-Lehmann shift + CI
Paired or one-sampleWilcoxon signed-rankwilcox.test(x, y, paired = TRUE)V, p, rank-biserial r, pseudomedian + CI
Three or more groupsKruskal-Walliskruskal.test(list(...))H, df, p, epsilon-squared
Direction onlySign testbinom.test(sum(d > 0), n, 0.5)positives, p, proportion + CI

Frequently asked questions

When should I use a nonparametric test instead of a t-test or ANOVA?

Reach for a rank-based test when the numbers are ordinal (like 1-5 ratings), when the sample is small and clearly non-normal, or when outliers would distort a mean. Rank tests compare distributions through their ranks, so they do not assume normality and they resist outliers. When the data are roughly normal, a t-test or ANOVA has slightly more power.

What is the difference between the Mann-Whitney U and the Wilcoxon signed-rank test?

Mann-Whitney U (the Wilcoxon rank-sum test) compares two independent groups, like treatment versus control. The Wilcoxon signed-rank test compares two paired measurements on the same subjects (before versus after) or one sample against a reference value. Independent samples use rank-sum; paired or one-sample data use signed-rank.

How does this calculator compute exact p-values?

When the sample is small and there are no ties, it builds the exact permutation distribution of the rank statistic (the same recurrence R uses for pwilcox and psignrank) and reads the p-value off it. With ties, zeros, or larger samples it switches to the normal approximation with a continuity correction and a tie correction to the variance, exactly like R's wilcox.test.

What effect size does it report?

For two groups it reports the rank-biserial correlation, which equals Cliff's delta and ranges from -1 to 1. For the signed-rank test it reports the matched-pairs rank-biserial correlation. For Kruskal-Wallis it reports epsilon-squared. All three match the effectsize package.

What is the Hodges-Lehmann estimate?

It is the nonparametric counterpart of the mean difference: the median of all pairwise differences between the two groups (rank-sum) or the median of the Walsh averages (signed-rank). The tool reports it with the distribution-free confidence interval that R returns from wilcox.test(conf.int = TRUE).

Do ties or zeros change the result?

Yes. Ties make an exact p-value ambiguous, so the tool uses the normal approximation with a variance correction for tied ranks. In the signed-rank and sign tests, pairs with a zero difference carry no direction and are dropped before counting, which reduces the effective sample size. The tool tells you when it has switched to the approximation.

Does this match R exactly?

Yes. The statistic, p-value, effect size and Hodges-Lehmann interval match stats::wilcox.test, kruskal.test and binom.test and the effectsize package, verified against R 4.6.0. The R code shown pins exact= and correct= so pasting it reproduces the number on screen.

Keep learning