Tests whether the differences between two measurements of the same subjects lean one way, using ranks. The absolute differences are ranked, and the ranks of the positive and negative differences are compared. It is the paired t-test without the assumption of normality.
This tests whether the differences between two measurements of the same subjects lean one way, using ranks. It stands in for the paired t-test where normality cannot be assumed.
There are three steps. Take the difference for each pair and drop any that are zero. Rank the absolute differences from smallest to largest. Then compare , the sum of the ranks belonging to positive differences, with , the sum belonging to negative ones.
With no systematic difference the two sums should come out similar. The smaller of them is the test statistic .
Eight before-and-after pairs give differences of 3, 2, −1, 4, 3, 3, 2, 3. The positive rank sum is 35 and the negative one 1, adding to 36, which matches . With , and a p-value of 0.016, the after measurements are larger at the 5% level.
The sign test counts only how many differences are positive. Using the ranks of their sizes as well makes this test more likely to find a real difference, while still needing no normal distribution.
Pairs with a difference of zero point neither way and are dropped. If every difference is zero there is nothing to test.
Differences of equal size share a rank. They too are given the average rank, with the variance corrected accordingly.