estimateDc {densityClust} R Documentation

## Estimate the distance cutoff for a specified neighbor rate

### Description

This function calculates a distance cutoff value for a specific distance matrix that makes the average neighbor rate (number of points within the distance cutoff value) fall between the provided range. The authors of the algorithm suggests aiming for a neighbor rate between 1 and 2 percent, but also states that the algorithm is quite robust with regards to more extreme cases.

### Usage

estimateDc(distance, neighborRateLow = 0.01, neighborRateHigh = 0.02)


### Arguments

 distance A distance matrix neighborRateLow The lower bound of the neighbor rate neighborRateHigh The upper bound of the neighbor rate

### Value

A numeric value giving the estimated distance cutoff value

### Note

If the number of points is larger than 448 (resulting in 100,128 pairwise distances), 100,128 distance pairs will be randomly selected to speed up computation time. Use set.seed() prior to calling estimateDc in order to ensure reproducable results.

### References

Rodriguez, A., & Laio, A. (2014). Clustering by fast search and find of density peaks. Science, 344(6191), 1492-1496. doi:10.1126/science.1242072

### Examples

irisDist <- dist(iris[,1:4])
estimateDc(irisDist)



[Package densityClust version 0.3.2 Index]