Create a K-nearest neighbor graph from data x. Uses
nn2 as a fast way to find the neares neighbors.
makeKNNgraph(x, k, eps = 0, diag = FALSE)an object of type igraph with edge
weight being the distances.
data, a matrix, observations in rows, dimensions in columns
the number of nearest neighbors.
number, if eps > 0 the KNN search is approximate,
see nn2
logical, if TRUE every edge of the returned
graph will have an edge with weight 0 to itself.