# Wilcoxon Test

Also referred to as Wilcoxon matched-pairs signed ranks
can be used on paired matched scores
This can be used when sets of scores can be paired off
This returns the Wilcoxon's T statistic
This type of test an be used with both one and two tailed tests.

### Example

Lets imagine we buy a carrot cake from Tesco's and another from Waitrose and we want to find out which one people prefer.
Our hypothesis was that the cake from Waitrose would be better than one from Tesco's, so the hypothesis is a one-tailed hypothesis.

We are going to ask 10 people to try a slice of both and to rate each one out of 10.
The null hypothesis is that the two sets of results do not differ.

Subject | Waitrose | Tesco | Waitrose - Tesco

### Step 1

add another column to the table which is Waitrose - Tesco

### Step 2

Rank the differences according to size
SS - same table sorted by differences
Rank the scores from 1 to 9 (ignoring the signs)
Don't rank any differences of zero.

### Step 3

Add the ranks for all the positive differences
Add the ranks for all the negative differences

### Step 4

which ever total is smaller is the value of the Test statistic T
in this example T = 6.
This is not the answer but is the value of the T statistic
We can then use a stats table (pg 161) to tell us the probability level which will indicate if this result has arisen by chance or not.

To determine whether the value of T is significant count the number of pairs used (ignoring any where the difference is zero)
In this example there are 9 pairs of socres so N = 9.