jwcarr / mantel

Python implementation of the Mantel test, a significance test of the correlation between two distance matrices
MIT License
32 stars 19 forks source link

Integrate Kendall's tau #2

Closed jwcarr closed 8 years ago

jwcarr commented 9 years ago

Kendall's tau is not currently integrated into the optimized module (Mantel.py).

Firstly, I suspect it would be tricky to do any kind of optimization since most parts of the coefficient can't be pre-computed.

Secondly, Kendall's tau is computed very differently from the Pearson/Spearman correlation and it would be tricky to integrate Kendall elegantly without reducing the efficiency of Pearson/Spearman.

It may be worth removing Kendall entirely, since (a) Spearman provides a non-parametric correlation and (b) Kendall is already very slow, so many people would probably want to avoid it in a Mantel test.

My current solution is to keep it hanging around in the old module: Mantel_with_Kendall.py