Does the matlab ranksum function work for larger sample sizes?
显示 更早的评论
I'm using the matlab ranksum function for a power analysis of 2 samples and I'm getting statistical significance (small p-values). However, the textbook I have only uses the wilcoxon ransum test for non-parametric small sample sizes (sample sizes of 10 to 12), and my sample size is 50.
I wanted to know if the ranksum is still valid for larger sample sizes, or I'm getting these small p-values because my sample size is too large. Also, does anyone know what is the upper limit for a sample size that ranksum can handle?
Thanks.
采纳的回答
更多回答(2 个)
the cyclist
2017-7-20
编辑:the cyclist
2017-7-20
0 个投票
I would expect the test to be valid for large samples.
The danger as one moves from small samples to really large samples shifts from "Do I have enough data to see a meaningful effect?" to "I have so much data that I can detect really tiny differences between samples, but are these statistically significant differences actually meaningful?" It becomes more important to have a sense of what a meaningful effect size is.
For example, with a huge sample you might be able to detect a difference of 1 day between two 5-year survival curves. But even though it is statistically significant, it might not be clinically significant.
I don't believe there is a conceptual upper limit to sample size. Just a computer memory limit. :-)
Blanca Larraga
2018-11-28
0 个投票
I am using ranksum with two samples of 200 elements and I get a p value which does not make any sense and if I do the boxplot I can clearly see that there is no difference between the two samples even though I get h=1 and a p value really small. Is there any other function I should use for this prupose?
2 个评论
Elisa Iovene
2021-3-23
Hello Blanca, I’m having the same problem. Have you solved the problem? It would be really useful Thanks!
Even thought the topic here is relevant, you will not usually get any response from a question and comment that are 3 years old. (I happened to see it quite by accident.)
I never noticed @Blanca Larraga's note here. But it is pretty easy to create a distribution that has statistically different ranksum(), but doesn't look very different to the eye (if you have enough data points). In the below code, you can see the difference, but barely. And I wasn't even trying very hard. :-)
rng default
N=200;
x1 = randn(N,1);
x2 = x1 + 0.21;
[p,h] = ranksum(x1,x2)
figure
boxplot([x1 x2])
Can you post your data, and give more details? If you tag me with @, I'll try to take a look.
类别
在 帮助中心 和 File Exchange 中查找有关 Logistic Distribution 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
