Sign in to save

Bookmark this page so you can find it later.

Sign in to save

Bookmark this page so you can find it later.

The Mann-Whitney UU test is a nonparametric method for comparing two independent groups when a two-sample tt test may not be appropriate. It is commonly used when data are ordinal, skewed, or measured on a scale where normality is doubtful. This cheat sheet helps students organize the full walkthrough, from hypotheses to ranking, calculating UU, finding a pp-value, and stating a conclusion.

It is especially useful because small ranking errors can change the final test statistic.

The core idea is to combine both samples, rank all observations, and compare the rank totals between groups. For group sizes n1n_1 and n2n_2, compute U1=R1n1(n1+1)2U_1 = R_1 - \frac{n_1(n_1+1)}{2} and U2=R2n2(n2+1)2U_2 = R_2 - \frac{n_2(n_2+1)}{2}, then use U=min(U1,U2)U = \min(U_1,U_2) for many table-based tests. For large samples, UU can be standardized with z=UμUσUz = \frac{U - \mu_U}{\sigma_U}, where μU=n1n22\mu_U = \frac{n_1n_2}{2} and σU=n1n2(n1+n2+1)12\sigma_U = \sqrt{\frac{n_1n_2(n_1+n_2+1)}{12}} when there are no ties.

The final interpretation should connect the statistical result to the original context, not just report whether p<αp < \alpha.

Key Facts

  • The Mann-Whitney UU test compares two independent groups using ranks rather than raw data values.
  • The null hypothesis is usually H0H_0: the two population distributions are the same, while the alternative HaH_a states that one distribution tends to have larger values or that the distributions differ.
  • After combining both samples and ranking all observations, the rank sum for group 11 is R1R_1 and the rank sum for group 22 is R2R_2.
  • The test statistics are U1=R1n1(n1+1)2U_1 = R_1 - \frac{n_1(n_1+1)}{2} and U2=R2n2(n2+1)2U_2 = R_2 - \frac{n_2(n_2+1)}{2}.
  • The two UU statistics satisfy U1+U2=n1n2U_1 + U_2 = n_1n_2, which is a useful arithmetic check.
  • For many small-sample procedures, the reported statistic is U=min(U1,U2)U = \min(U_1,U_2).
  • For large samples with no ties, use μU=n1n22\mu_U = \frac{n_1n_2}{2} and σU=n1n2(n1+n2+1)12\sigma_U = \sqrt{\frac{n_1n_2(n_1+n_2+1)}{12}} to compute z=UμUσUz = \frac{U - \mu_U}{\sigma_U}.
  • A common rank-biserial effect size is rrb=12Un1n2r_{rb} = 1 - \frac{2U}{n_1n_2} when UU is the smaller UU statistic.

Vocabulary

Mann-Whitney U test
A nonparametric test that compares two independent groups by analyzing the ranks of all observations.
Rank sum
The total of the assigned ranks for one group after all observations from both groups are combined and ordered.
Independent samples
Samples are independent when observations in one group are not paired with or directly related to observations in the other group.
Tie
A tie occurs when two or more observations have the same value and must receive the average of their rank positions.
Normal approximation
A large-sample method that converts the UU statistic to a zz score so a normal distribution can estimate the pp-value.
Rank-biserial correlation
An effect size that describes the strength and direction of the difference between two groups based on rank dominance.

Common Mistakes to Avoid

  • Ranking the two groups separately is wrong because the Mann-Whitney UU test requires ranking all observations together in one combined list.
  • Ignoring ties is wrong because tied observations should receive average ranks, and many large-sample calculations need a tie correction when ties are frequent.
  • Using the larger UU when a table expects U=min(U1,U2)U = \min(U_1,U_2) is wrong because many critical-value tables are built for the smaller of the two statistics.
  • Treating the test as automatically comparing means is wrong because the Mann-Whitney UU test primarily compares rank distributions and is often interpreted as a difference in typical values only under similar distribution shapes.
  • Reporting only p<αp < \alpha is incomplete because a good conclusion should include the context, direction of the difference, and an effect size such as rrbr_{rb} when appropriate.

Practice Questions

  1. 1 Two independent samples have n1=5n_1 = 5, n2=6n_2 = 6, and group 11 rank sum R1=24R_1 = 24. Compute U1U_1, U2U_2, and U=min(U1,U2)U = \min(U_1,U_2).
  2. 2 For n1=12n_1 = 12 and n2=10n_2 = 10 with no ties, compute μU=n1n22\mu_U = \frac{n_1n_2}{2} and σU=n1n2(n1+n2+1)12\sigma_U = \sqrt{\frac{n_1n_2(n_1+n_2+1)}{12}}.
  3. 3 A study reports U=18U = 18, n1=8n_1 = 8, and n2=9n_2 = 9. Compute the rank-biserial effect size using rrb=12Un1n2r_{rb} = 1 - \frac{2U}{n_1n_2}.
  4. 4 Explain why the Mann-Whitney UU test may be preferred over an independent two-sample tt test for ordinal survey ratings or strongly skewed data.