MATLAB: How to change the significance level of either kruskalwallis or ranksum test

alphakruskalwallisranksumsignificance levelwilcoxon

Hi, this is probably an easy question for rehular matlab users but leaves me standing infront of a problem: the default significance level of kruskalwallis is 0.01 and the obe for ranksum 0.05…I would like to use the same for both and found that you can change it just not "how". Where in the code do you put the alpha value in?
I typed it in like you would for a t-test but that should change the p-value depending on your significance level i.e. if the null hypothesis gets just about accepted with 0.05 it should be rejected with 0.01. However, the p-value remains the same in both cases…
Thanks!

Best Answer

For ranksum, you have to specify it as a name-value pair as 'alpha' (link).
The kruskalwallis doesn’t have that option. However, it outputs the p-value, so you can use it to make your own decisions.