# [R] Wilcoxon signed rank test and its requirements

David Winsemius dwinsemius at comcast.net
Fri Jun 25 00:17:49 CEST 2010

```On Jun 24, 2010, at 6:09 PM, Joris Meys wrote:

> I do agree that one should not trust solely on sources like wikipedia
> and graphpad, although they contain a lot of valuable information.
>
> This said, it is not too difficult to illustrate why, in the case of
> the one-sample signed rank test,

That is a key point. I was assuming that you were using the paired
sample version of the WSRT and I may have been misleading the OP. For
the one-sample situation, the assumption of symmetry is needed but for
the paired sampling version of the test, the location shift becomes
the tested hypothesis, and no assumptions about the form of the
hypothesis are made except that they be the same. Any consideration of
median or mean (which will be the same in the case of symmetric
distributions) gets lost in the paired test case.

--
David.

> the differences should be not to far
> away from symmetrical. It just needs some reflection on how the
> statistic is calculated. If you have an asymmetrical distribution, you
> have a lot of small differences with a negative sign and a lot of
> large differences with a positive sign if you test against the median
> or mean. Hence the sum of ranks for one side will be higher than for
> the other, leading eventually to a significant result.
>
> An extreme example :
>
>> set.seed(100)
>> y <- rnorm(100,1,2)^2
>> wilcox.test(y,mu=median(y))
>
>        Wilcoxon signed rank test with continuity correction
>
> data:  y
> V = 3240.5, p-value = 0.01396
> alternative hypothesis: true location is not equal to 1.829867
>
>> wilcox.test(y,mu=mean(y))
>
>        Wilcoxon signed rank test with continuity correction
>
> data:  y
> V = 1763, p-value = 0.008837
> alternative hypothesis: true location is not equal to 5.137409
>
> Which brings us to the question what location is actually tested in
> the wilcoxon test. For the measure of location to be the mean (or
> median), one has to assume that the distribution of the differences is
> rather symmetrical, which implies your data has to be distributed
> somewhat symmetrical. The test is robust against violations of this
> -implicit- assumption, but in more extreme cases skewness does matter.
>
> Cheers
> Joris
>
> On Thu, Jun 24, 2010 at 7:40 PM, David Winsemius <dwinsemius at comcast.net
> > wrote:
>>
>>
>> You are being misled. Simply finding a statement on a statistics
>> software
>> website, even one as reputable as Graphpad (???), does not mean
>> that it is
>> necessarily true. My understanding (confirmed reviewing
>> "Nonparametric
>> statistical methods for complete and censored data" by M. M. Desu,
>> Damaraju
>> Raghavarao, is that the Wilcoxon signed-rank test does not require
>> that the
>> underlying distributions be symmetric. The above quotation is highly
>> inaccurate.
>>
>> --
>> David.
>>
>>>
>
> --
> Joris Meys
> Statistical consultant
>
> Ghent University
> Faculty of Bioscience Engineering
> Department of Applied mathematics, biometrics and process control
>
> tel : +32 9 264 59 87
> Joris.Meys at Ugent.be
> -------------------------------
> Disclaimer : http://helpdesk.ugent.be/e-maildisclaimer.php

```