plotKNN-methods: Plot kNN graph.

plotKNNR Documentation

Plot kNN graph.

Description

Plot the kNN graph generated by buildKNN and stored at CellRouter@graph. The graph could also be generated by the findClusters function.

Usage

plotKNN(
  object,
  assay.type = "RNA",
  reduction.type = "tsne",
  column.ann,
  column.color,
  dims.use = c(1, 2)
)

## S4 method for signature 'CellRouter'
plotKNN(
  object,
  assay.type = "RNA",
  reduction.type = "tsne",
  column.ann,
  column.color,
  dims.use = c(1, 2)
)

Arguments

object

CellRouter object.

assay.type

character; the type of data to use.

reduction.type

character; the reduced dimension space used to visualize the kNN graph: tsne, pca, dc or custom.

column.ann

character; column in the metadata table used to annotate the kNN graph. For example, clusters, sorted cell populations...

column.color

character; column in the metadata table corresponding to the color used to annotate the kNN graph. Should correspond to the metadata in column.ann.

dims.use

numeric; dimensions to plot.

Value

ggplot2; plot.


edroaldo/fusca documentation built on March 1, 2023, 1:43 p.m.