Kruskal-Wallis test
The Kruskal-Wallis test is a non-parametric method that compares medians across three or more independent groups by ranking all observations together, used when ANOVA's normal-distribution assumption is not met.
See it move
Loading infographic...
Three delivery teams' nine wait times are ranked together from 1 to 9, giving rank sums of 15, 24 and 6. The test statistic H = (12 ÷ 90) × (15²/3 + 24²/3 + 6²/3) − 30 works out to 7.2, which exceeds the chi-square critical value of 5.99 for 2 degrees of freedom, so the teams' distributions are not all equal.
Where it fits
SubjectData Analysis & StatisticsAdvancedTopicCommon Significance TestsAdvanced
The formula
LaTeX
Variables
- Total number of observations across all groups
- Number of groups
- Sum of ranks in group i
- Number of observations in group i
Converts rank sums into a test statistic that follows a chi-square distribution with k − 1 degrees of freedom under the null hypothesis of equal distributions.