cachePermute | R Documentation |
What do you do when you have to compute pairwise distances many times, and those damn distances take a long time to compute? Answer: You cache the distances and permute the underlying sample labels!
cachePermute(dists, forward, reverse)
dists |
|
forward |
|
reverse |
|
This function permutes the distances (Hamming, l_p^p
, etc.) within blocks.
Permutations respect the fact that we are actually permuting the
underlying labels. Arguments forward and reverse should be
precomputed using buildForward and buildReverse.
Dependencies: buildForward, buildReverse
A matrix with same dimensions as dists containing the block-permuted pairwise distances
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.