Skip to contents

Takes a single cell object, a grouping variable, a factor within the group to test, and an ident class (i.e. clusters). Per level of ident performs hypergeometric testing for enrichment of group factor

Usage

plotCellsPerGroup(
  sc.obj = NULL,
  group = NULL,
  order = TRUE,
  trans = NULL,
  threshold = 100,
  plot = TRUE,
  label = TRUE,
  sep = ";"
)

Arguments

sc.obj

single cell object in Seurat or SingleCellExperiment format containing group metadata

group

a column of metadata in sc.obj

order

Logical. Rank order levels of group by cell number

trans

From ggplot2. For continuous scales, the name of a transformation object or the object itself.

threshold

threshold number of cells above which labels for group levels will appear

plot

Logical. Plot results or return data.

label

Logical. Label group levels above cell number threshold. if ggrepel is installed will use geom_text_repel instead of geom_text

sep

Separating character used for aggregation (string). Default = `;`.

Value

Returns a plot of cell number by barcode test results or underlying plot data

Details

plotCellsPerGroup

Plots number of cells for each detected barcode in a single cell dataset