Kruskal-Wallis ANOVA: Non-Parametric Analysis for Multiple Independent Groups
Overview
When a researcher needs to compare more than two independent groups on some variable of interest, but the data violate the assumptions of one-way ANOVA (normality, homogeneity of variance), the Kruskal-Wallis one-way analysis of variance by ranks provides the non-parametric solution. Developed by Kruskal (1952) and Kruskal & Wallis (1952), it extends the Mann-Whitney U test to designs with groups.
The Kruskal-Wallis test is essentially one-way ANOVA performed on ranked data. Instead of comparing group means, it compares group medians by converting all scores to ranks and examining whether rank sums differ across groups more than expected by chance.
3.2 Why Not Just Run Multiple t-Tests?
A common student impulse is to handle groups by running all pairwise comparisons. Consider the escalation problem:
| Number of Groups (k) | Pairwise Comparisons Needed |
|---|---|
| 2 | 1 |
| 3 | 3 |
| 4 | 6 |
| 5 | 10 |
| 6 | 15 |
With groups, you'd need 10 separate t-tests. This is problematic for two reasons:
- Computational burden: Each test requires complete data processing
- Type I Error inflation: With α = .05 per test, running 10 tests gives a family-wise error rate approaching — meaning there's a 40% chance of at least one false positive even if all null hypotheses are true
The ANOVA family of tests (both parametric and non-parametric) was developed precisely to address this problem — they compare all groups simultaneously in a single omnibus test while controlling the overall Type I error rate at the desired α level.
Parametric ANOVA: A Brief Review
One-way (parametric) ANOVA, developed by Sir Ronald Fisher, examines variability in a response variable (Y) to determine whether it can be attributed to group membership (X). The logic:
ANOVA requires:
- Random, independent sampling from each of the populations
- Normal population distributions
- Equal variances across the populations (homogeneity of variance)
When assumptions 2 and 3 are violated with small samples, Kruskal-Wallis ANOVA is the appropriate substitute.
3.3 Introduction to the Kruskal-Wallis Test
The Kruskal-Wallis test operates with the following hypotheses:
Relationship to Other Tests
When , the Kruskal-Wallis test yields results identical to the Mann-Whitney U test. The Kruskal-Wallis test is thus a direct extension of Mann-Whitney to the multi-group case.
3.4 Assumptions of the Kruskal-Wallis Test
Sources including Conover (1980, 1999), Daniel (1990), and Siegel & Castellan (1988) specify these assumptions:
- Random sampling: Each sample randomly selected from its population
- Independence: The samples are independent of one another
- Continuous dependent variable: The original variable (subsequently ranked) is ideally continuous. In practice, discrete variables are frequently used.
- Identical distribution shape: Underlying populations have the same distributional shape (not necessarily normal)
Maxwell and Delaney (1990) note that assumption 4 (identical shapes) implies homogeneity of variance — the same implicit assumption noted for the Mann-Whitney U test. The Kruskal-Wallis test is less sensitive to variance heterogeneity than the F-test (Zimmerman & Zumbo, 1993), but this assumption is not entirely absent.
Why Rank Data? The Outlier Problem
In multi-group research, outliers can:
- Inflate variance within groups (creating apparent heterogeneity)
- Distort group means (making ANOVA F-test unreliable)
- Mask true group differences
By converting scores to ranks, the Kruskal-Wallis test neutralises outlier influence — a score of 500 in a dataset where typical values are 10–50 simply becomes the highest rank, without distorting computations.
Self-Assessment Questions
Level 1 — Recall
-
Why can running multiple pairwise t-tests be problematic when comparing more than two groups? Name both issues.
-
What are the four assumptions of the Kruskal-Wallis test? How do they compare to the assumptions of one-way ANOVA?
-
True or False: The Kruskal-Wallis test requires normally distributed data. Explain your answer.
Level 2 — Application
-
A researcher has collected anxiety scores from five different therapy groups (n = 8 per group). Shapiro-Wilk tests reveal significant non-normality in two of the five groups. Should the researcher use one-way ANOVA or Kruskal-Wallis? Justify your choice.
-
With 6 groups, how many pairwise t-tests would be needed? What is the approximate family-wise Type I error rate if each test uses α = .05? Why is a single omnibus test preferable?
Level 3 — Critical Thinking
-
A textbook states: "The Kruskal-Wallis test is assumption-free." Critically evaluate this claim with reference to the actual assumptions of the test.
-
If the Kruskal-Wallis test yields a significant result (H₀ rejected), what can the researcher conclude? What can they not conclude, and what additional analyses might be needed?
🧠 Memory Aid
"KRUSKAL Ranks K groups"
- Kruskal-Wallis = K groups (k > 2, hence "K" for "many")
- Ranks all data together before computing H
- Uses medians, not means
- Substitutes for ANOVA when assumptions fail
- Key statistic = H (compare to chi-square table for large samples, Table H for small)
- Analogous to F-test in ANOVA
- Logic: if groups differ, rank sums will be unequal
📚 External Resources
Foundational Reading
- 🌐 Wikipedia: Kruskal-Wallis test — Complete mathematical background, assumptions, and examples
- 🌐 Wikipedia: One-way ANOVA — Parametric counterpart for comparison
Tutorials
- 📖 Laerd Statistics: Kruskal-Wallis Test — Comprehensive guide with SPSS screenshots
- 📖 Statistics How To: Kruskal Wallis H Test — Clear examples and interpretation guidance
- 📖 Real Statistics: Kruskal-Wallis Test — Excel and manual calculation
Videos
- 🎥 Kruskal-Wallis Test Explained — YouTube — Conceptual overview
- 🎥 SPSS Kruskal-Wallis Tutorial — Full SPSS walkthrough
Research Articles
- 📄 Kruskal, W. H., & Wallis, W. A. (1952). Use of ranks in one-criterion variance analysis. Journal of the American Statistical Association, 47(260), 583–621. (Original paper)
- 📄 Iman, R. L., & Conover, W. J. (1981). Rank transformations as a bridge between parametric and nonparametric statistics. The American Statistician, 35(3), 124–129.
- 📄 Vargha, A., & Delaney, H. D. (1998). The Kruskal-Wallis test and stochastic homogeneity. Journal of Educational and Behavioral Statistics, 23(2), 170–192.
Source PDFs:
- 📄 Block-4/Unit-3.pdf — Pages 34–38
- 📚 MPC-006 Statistics in Psychology