scipy.stats.ranksums¶
- scipy.stats.ranksums(x, y)[source]¶
Compute the Wilcoxon rank-sum statistic for two samples.
The Wilcoxon rank-sum test tests the null hypothesis that two sets of measurements are drawn from the same distribution. The alternative hypothesis is that values in one sample are more likely to be larger than the values in the other sample.
This test should be used to compare two samples from continuous distributions. It does not handle ties between measurements in x and y. For tie-handling and an optional continuity correction see scipy.stats.mannwhitneyu.
Parameters: x,y : array_like
The data from the two samples
Returns: z-statistic : float
The test statistic under the large-sample approximation that the rank sum statistic is normally distributed
p-value : float
The two-sided p-value of the test
References
[R309] http://en.wikipedia.org/wiki/Wilcoxon_rank-sum_test