Skip to main content
BetaLucidstat is in beta. Results are checked against R, but always verify them against your source data.Send feedback via EZY Research

Wilcoxon signed-rank test

The non-parametric alternative to the paired t-test for two repeated measurements.

6 min read

Try it

One click opens the “Teaching-method study” sample dataset with this test selected and the variables filled in. Or use your own data.

The Wilcoxon signed-rank test is the non-parametric alternative to the paired t-test. It compares two measurements from the same people using the ranks of the differences instead of the differences themselves, so it does not assume the differences are normal.

When to use it

  • You have two measurements from the same people (or matched pairs), and
  • the data are ordinal, such as a single Likert item before and after, or
  • the differences are not normal and there are fewer than 30 pairs, or there are severe outliers.

The idea

  1. Compute each person's difference (first − second) and drop pairs with a difference of 0.
  2. Rank the size of the differences, ignoring the sign.
  3. Add up the ranks of the positive and the negative differences separately.
  4. With no change, the two sums should be similar. The statistic T is the smaller of the two sums: the smaller T, the more consistently scores moved in one direction.

Lucidstat converts T to z (with tie and continuity corrections, as R wilcox.test) and reports r = |z| ÷ √N.

Worked example

This uses the same pre-test and post-test scores as the paired t-test lesson (89 pairs).

Medians and quartiles
MeasurementnMdnQ1Q3
Pre-test8953.0048.0060.50
Post-test8966.0061.0075.00
Signed ranks (pre-test − post-test)
RanksnSum of ranks
Positive (pre > post)28.5
Negative (pre < post)873996.5
Ties0

Result: T = 8.5, z = −8.16, p < .001, r = .87.

How to read it

  • 87 of 89 students scored higher on the post-test, so the sum of positive ranks is tiny (T = 8.5).
  • p < .001: pre-test and post-test scores differ significantly.
  • r = .87 is far above the "large" benchmark of .50.
  • The result agrees with the paired t-test on the same data, so the conclusion does not depend on the distribution of the differences.
Reporting example (APA 7)

A Wilcoxon signed-rank test showed that Pre-test (Mdn = 53.00) differed significantly from Post-test (Mdn = 66.00), T = 8.5, z = −8.16, p < .001, r = .87, a large effect. Pre-test was higher than Post-test for 2 of 89 pairs.

Reporting example (Thai thesis style)

ผลการทดสอบ Wilcoxon signed-rank พบว่า คะแนนก่อนเรียน (Mdn = 53.00) และคะแนนหลังเรียน (Mdn = 66.00) แตกต่างกันอย่างมีนัยสำคัญทางสถิติที่ระดับ .05 (T = 8.5, z = −8.16, p < .001) โดยคะแนนก่อนเรียนสูงกว่าคะแนนหลังเรียน จำนวน 2 คู่จาก 89 คู่ และขนาดอิทธิพลอยู่ในระดับใหญ่ (r = .87)

Common mistakes

  • Using it for two groups of different people. Use the Mann–Whitney U test.
  • Not reporting pairs with zero difference, which are dropped from the calculation.
  • Reading the direction from the sign of z instead of the medians.

References

  • Rosenthal, R. (1991). Meta-analytic procedures for social research (Rev. ed.). Sage.
  • Wilcoxon, F. (1945). Individual comparisons by ranking methods. Biometrics Bulletin, 1(6), 80–83.

Try it

One click opens the “Teaching-method study” sample dataset with this test selected and the variables filled in. Or use your own data.

Related lessons