Skip to contents

Function to create a shared nearest neighbors graph, implemented with DBSCAN

Usage

createSharedNNGraph.Region(
  object,
  k,
  kt = NULL,
  jp = FALSE,
  representation = "spatial",
  name = NULL,
  ...
)

Arguments

object

A Region object

k

The number of nearest neighbors to consider when calculating shared nearest neighbors

kt

The minimum threshold on the number of shared nearest neighbors to build the SNN graph. Edges are only preserved if kt or more neighbors are shared.

jp

Use the definition of SNN by Jarvis and Patrick (1973). Shared neighbors are only counted between points that are in each other's neighborhood. Otherwise 0 is returned.

representation

The name of the representation, with associated cell embeddings, to be used to compute the frNN graph

name

The name of the NN graph. Internal.

...

Additional arguments passed to dbscan::sNN()

Details

Shared nearest neighbors is a K nearest neighbor network that guarantees that all edges are mutual.

Scroll to top