Closed tomwenseleers closed 7 years ago
You can enter distance matrix if you want to use more exotic distances. For example, use clustering_distance_cols = dist((1-cor(mat, method = "kendall")))
Per issue #41, we should actually use as.dist
rather than dist
. My understanding is that dist
will recalculate distances of the 1-cor(mat, method = "kendall")
distances (distance of distances), rather than convert the calculated distances to a dist
object.
Currently, I noticed that if one chooses 1-correlation as the distance metric for clustering that only a Pearson correlation can be used, and not kendall tau or spearman rank.
I was wondering if you would mind supporting those too by any chance? (Allowing argument method to be passed to cor() would be a simple fix, but more elegant would probably be to allow "kendall" or "spearman" in addition to "correlation" or "pearson" for a standard Pearson correlation.)