SharedNeighborDistance {BIDistances} | R Documentation |
Shared Neighbor Distance
Description
Calculates the Shared Neighbor Distance
Usage
SharedNeighborDistance(Data, k = 5, NThreads = NULL, ComputationInR = FALSE)
Arguments
Data |
[1:n,1:d] matrix with n cases, d variables |
k |
Integer defining the number of nearest neighbors |
NThreads |
Number of threads in parallel computation. |
ComputationInR |
Boolean (Default ComputationInR = FALSE). If FALSE, do computation in Rcpp, else in R (very slow). |
Value
Distance |
[1:n,1:n] symmetric matrix, containing the distanes of the cases (rows) for the given data |
Author(s)
Quirin Stier
References
https://github.com/albert-espin/snn-clustering/blob/master/SNN/snn.py
Examples
data(Hepta)
distMatrix = SharedNeighborDistance(Hepta$Data, NThreads = 1, ComputationInR=TRUE)
[Package BIDistances version 0.1.3 Index]