Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

umap.knn

construct a umap.knn object describing nearest neighbors


Description

construct a umap.knn object describing nearest neighbors

Usage

umap.knn(indexes, distances)

Arguments

indexes

matrix, integers linking data points to nearest neighbors

distances

matrix, distance values between pairs of points specified in the matrix of indexes

Value

object of class umap.knn, which is a list with matrices with indexes of nearest neighbors and distances to those neighbors

Examples

# this example describes a set of three data points (indexes 1,2,3)
# which are equidistant from each other. Hence the distance between
# pairs (i, j) is 0 for i=j and 1 otherwise.
three.indexes = matrix(c(1,2,3,
                         2,1,3,
                         3,1,2), nrow=3, ncol=3)
three.distances = matrix(c(0, 1, 1,
                           0, 1, 1,
                           0, 1, 1), nrow=3, ncol=3)

umap.knn(three.indexes, three.distances)

umap

Uniform Manifold Approximation and Projection

v0.2.7.0
MIT + file LICENSE
Authors
Tomasz Konopka [aut, cre]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.