# Wilcoxon signed-rank test

## Wilcoxon signed-rank test

Comparison of central tendencies of two dependent samples.

## Requirements:

Dependent variable must be interval scaled because differences are taken for the test. Distribution is free.

## Idea:

Dependency of the two sample data is considered by taking the differences of paired values. The calculation of differences requires at least interval scaled data. In a next step the differences are brought into rank order. Under H0 the sum of positive differences should approximately equal the sum of negative differences. Zero-Differences are not considered in the test.

## Measure:

T = Sum of ranks of less frequent sign.

## Approximation with Normal Distribution:

For large sample sizes (n = Number of pairs > 25) T is approximately normal distributed with

and

## Test:

If there are tied ranks, σT is corrected as follows:

Whereas

ti = Number of subjects sharing rank i

k = Number of tied ranks

## Example of a Wilcoxon signed-rank test

A driving instructor is interested on the effect of alcohol on the fitness to drive. Learners had to drive the same test course with 0 per mill and with 0.8 per mill blood alcohol level. Driving errors of the learners were measured. The following table shows the raw data and rank scores for each learner.

 Perf. BAL 0.8 Perf. BAL 0.0 Diff. 0.8-0.0 abs. Diff. Rank of abs. Diff. 3 1 2 2 16.5 2 2 0 0 0 1 -1 1 6.5 * 3 0 3 3 21.5 1 0 1 1 6.5 2 2 0 0 1 0 1 1 6.5 3 1 2 2 16.5 1 0 1 1 6.5 0 0 0 0 1 0 1 1 6.5 3 1 2 2 16.5 2 1 1 1 6.5 4 2 2 2 16.5 2 0 2 2 16.5 2 3 -1 1 6.5 * 0 1 -1 1 6.5 * 1 0 1 1 6.5 2 0 2 2 16.5 2 1 1 1 6.5 3 1 2 2 16.5 1 0 1 1 6.5 4 0 4 4 24 5 1 4 4 24 2 3 -1 1 6.5 * 5 2 3 3 21.5 1 1 0 0 3 1 2 2 16.5 4 0 4 4 24

Notice that 0 differences are left out. There are four negative differences (*). All other differences are positive.

T = Sum of ranks of less frequent sign

T = 26

The obtained z-Value is smaller than the critical z-Value (5% two-tailed). A blood alcohol level of 0.8 per mill leads to a significant degradation of driving performance.

BrightStat output of the Wilcoxon test example

This is a fictitious example.

## References

Bortz, J. (2005). Statistik für Human- und Sozialwissenschaftler (6th Edition). Heidelberg: Springer Medizin Verlag.

Conover, W.J. (1999). Practical nonparametric Statistics.(3rd edition). Wiley.

Schaich, H.E. & Hamerle, A. (1984). Verteilungsfreie statistische Prüfverfahren, Berlin.

Wilcoxon, F. (1945). Individual comparisons by ranking methods. Biometrics Bulletin 1, (6), 80 – 83.