Pvalue for Spearman Correlation in julia

How to find correlation pvalue in case of spearman method?

For Pearson, it’s straightforward with function CorrelationTest() but I couldn’t find something similar for spearman.

While we wait for a proper answer, it may be equivalent to tiedranking your variables and then using CorrelationTest.

1 Like

I think this is the only way. I don’t see any direct function.

It would be better to have CorrelationTest() with some method argument such as pearson, kendell or spearman etc. :slight_smile:

1 Like

Hi. Yes, this is a little problematic.

I discussed a possible solution to it in my book. If you are interested here is Exercise 1 from ch07 (Exercises - Association and Prediction - Romeo and Julia, where Romeo is Basic Statistics) and the solution (Solutions - Association - Romeo and Julia, where Romeo is Basic Statistics).

Hope it will be helpful.

2 Likes