Contents Up << >>

Wilcoxon

Format: W[ilcoxon] [s[igned]] [column]
This command performs Wilcoxon's rank sum test to compare the values in two groups to say whether the values are generally higher in one group than those in the other. It is exactly equivalent to two other commonly used nonparametric tests, the Mann-Whitney U test and Kendall's S, so only one of these tests is provided.

Alternatively Wilcoxon's signed rank sum test can be applied to test whether the values in a column are generally greater than or less than 0. It would generally be used to compare two columns in a pairwise manner.

Example:

Enter command -  w c15
Enter condition for first group:   SEX=1
Enter condition for second group:   SEX=2
Output:

Wilcoxon's comparison of two groups:
Number (%)     Sum of ranks       Mean   Group
73  (73.0%)  T0  3804.0     3686.5     SEX=1
27  (27.0%)  T1  1246.0     1363.5     SEX=2
Variance:  16554.807     (Sum-mean)/sd:  0.913
One-tailed p = 0.1805
The rank sum is taken as approximating to a normal distribution with mean and standard deviation derived as described by Armitage and Berry. The probability value given is the probability of the rank sum reaching a value of such magnitude assuming this normal distribution. For low numbers in each group the user may prefer to refer to a set of tables quoting the exact probability value for the rank sum dependent on the numbers in each group.

If the SIGNED option (which can be abbreviated down to S) is specified then Wilcoxon's signed rank sum test is used to determine whether the values in a column are significantly less than or greater than zero. The usual application of this would be to first make one column the difference between two others using the DERIVE command, and then to perform the signed rank test on it. This would then be a pairwise test of whether the values in one column were higher than those in the other.

Example:

Enter command -  new c3 diff
Enter command -  derive c3 c1-c2
Enter command -  w s c3
Output:

Wilcoxon's signed rank sum test using C3 (DIFF)
n' = 25   T+ = 24.0   T- = 301.0
Variance = 1338.5
Standardised normal deviate with continuity correction = 3.772
One-tailed p = 0.0001
Here the DERIVE command is first used to make the values in c3 equal to the differences between the values in c1 and c2. Then the signed rank test is applied to c3 to provide a pairwise test of whether the values in c1 are signficantly higher or lower than in c2.