Wilcoxon's Signed Ranks Test

 

Menu location: Analysis_Nonparametric_Wilcoxon Signed Ranks.

 

This is a method for the comparison of a pair of samples.

 

The Wilcoxon signed ranks test statistic T+ is the sum of the ranks of the positive, non-zero differences (Di) between a pair of samples.

 

Assumptions of tests on T+:

 

In most situations you should use a two sided test. A two sided test is based upon the null hypothesis that the common median of the differences is zero. The approximate alternative hypothesis in this case is that the differences tend not to be zero. For a lower side test the approximate alternative hypothesis is that differences tend to be less than zero. For an upper side test the approximate alternative hypothesis is that differences tend to be greater than zero.

 

A confidence interval is constructed for the difference between the population medians. In sample terms this is called the confidence interval for the median or mean difference. It is also known as the Hodges-Lehmann estimate of shift. The assumptions of this method are:

 

Technical Validation

Exact permutational probability associated with the test statistic is calculated for sample sizes of less than 50. A normal approximation is used with sample sizes of 50 or more. Note that StatsDirect uses more accurate methods than some other statistical software for calculating probabilities associated with this statistic, therefore, you may notice a difference in results, especially where there are tied observations - you should find that StatsDirect and StatExact give the same answers. Confidence limits are calculated using critical values for k with sample sizes up to 30 or by calculating K* for samples with more than 30 observations (Conover, 1999; Neumann, 1988).

 

Example

From Conover (1999).

Test workbook (Nonparametric worksheet: First Born, Second Born).

 

The following data represent agressivity scores for 12 pairs of monozygotic twins.

 

First Born Second Born
86 88
71 77
77 76
68 64
91 96
72 72
77 65
91 90
70 65
71 80
88 81
87 72

 

To analyse these data in StatsDirect you must first enter them into two columns in the workbook. Alternatively, open the test workbook using the file open function of the file menu. Then select the Wilcoxon Signed Ranks from the Nonparametric methods section of the analysis menu. Select the columns marked "Firstborn" and "Second twin" when prompted for data.

 

For this example:

 

two sided P = 0.4756

median difference = 1.5

95.8% confidence interval for the difference between population medians = -2.5 to 6.5

 

Assuming that the paired differences come from a symmetrical distribution then these results show that one group did not tend to yield different results to the other group which was paired with it, i.e. there was no statistically significant difference between the agressivity scores of the first born as compared with the second twin. The extent of this lack of difference is shown well by the confidence interval which clearly encompasses zero. Note that the quoted 95.1% confidence interval is as close as you can get to 95% because of the mathematics involved in nonparametric methods like this.

 

P values

confidence intervals