# Spearmans Rank

#### benracer

##### New Member
Here is my data...

x 5 9 2 5 6 8 6 3
y 10 3 7 6 2 3 8 5

The spearmans rank correlation coefficiant is ment to equal 0.482

All i get is -0.619

If i square the difference and find the sum i get 136 though the answer book shows it to be 124.5 though i cannot understand why.

Thanks

#### Dragan

##### Super Moderator
Here is my data...

x 5 9 2 5 6 8 6 3
y 10 3 7 6 2 3 8 5

The spearmans rank correlation coefficiant is ment to equal 0.482

All i get is -0.619

If i square the difference and find the sum i get 136 though the answer book shows it to be 124.5 though i cannot understand why.

Thanks

You forgot to rank the data!

#### benracer

##### New Member
SORTED!!! Thanks you just saved me some marks in my final GCSE exam tomorrow!

#### Dragan

##### Super Moderator

Rank separately x and y, R[x] and R[y], where you average the ranks when there are tied scores.

R[x] 3.5, 8, 1, 3.5, 5.5, 7, 5.5, 2

R[y] 8, 2.5, 6, 5, 1, 2.5, 7, 4

Now use Spearman's formula.

#### benracer

##### New Member
thanks, does it matter which way round it is ranked.? 1 to 8 or 8 to 1

#### Dragan

##### Super Moderator
thanks, does it matter which way round it is ranked.? 1 to 8 or 8 to 1

Well, you can rank either from low to high or from high to low - just be consistent for both x and y.