Explaining Statistical Tests – Wilcoxon Rank Sum (and Kruskal Wallis)

So, mostly on here, I’ve talked about parametric tests, or tests based on the normal distribution, but now we’re going to venture into a simple nonparametric test.  Much like the t test and its cousin the F Test, the Wilcoxon Rank sum (WRS) and Kruskal Wallis Test (KW) are tests of difference.  They are both rank tests, so the first step is to dump all of the values together and rank them while retaining which group they came from.  Then you sum the ranks of each group, treating each tie as an average of the ranks that tied (ie if you tied 3,4,5 then all three would be assigned a 4).  The score is the difference of the sum.  To find a p value for this test, you assume that each value is equally likely to end up with either group if the null hypothesis is true, so you do all the possible combinations of values and find scores for those combinations; your p value is how extreme your original value is, that is if there are 32 combinations and your original sum was higher than all but 3, your p value is 3/32 or .094.

This test is most useful when it’s hard to make a lot of assumptions about the distribution.  This test only assumes that the values are randomly assigned.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s