kNNCoords {EmbedSOM}R Documentation

Add KNN-topology-based embedding coordinates to the map

Description

Internally, this uses FNN::get.knn() to compute the k-neighborhoods. That function only supports Euclidean metric, therefore kNNCoords throws a warning whenever a different metric is used.

Usage

kNNCoords(
  k = 4,
  dim = NULL,
  distFn = function(x) x,
  layoutFn = igraph::layout_with_kk
)

Arguments

k

Size of the neighborhoods (default 4)

dim

Dimension of the result (passed to layoutFn)

distFn

Custom transformation function of the distance matrix

layoutFn

iGraph-compatible graph layouting function (default igraph::layout_with_kk)

Value

a function that transforms the map, usable as coordsFn parameter


[Package EmbedSOM version 2.1.2 Index]