Differential expression per cluster

diffExpPerCluster(object, ...)

# S4 method for SingleCellExperiment
diffExpPerCluster(object, group,
  numerator, denominator, ...)

# S4 method for Seurat
diffExpPerCluster(object, group, numerator, denominator,
  ...)

Arguments

object

Object.

group

character(1). Group of interest for differential expression per cluster. Must be a factor column in colData().

numerator

character. Cells to use in the numerator of the contrast (e.g. treatment).

denominator

character. Cells to use in the denominator of the contrast (e.g. control).

...

Passthrough arguments to diffExp().

Value

list containing:

  • caller = "edgeR": DGELRT.

  • caller = "DESeq2": DESeqResults.

Note

Updated 2019-08-06.

Cluster identity (ident) must be defined in colData() for this function to work.

Examples

data(Seurat, package = "acidtest") ## Seurat ==== object <- Seurat group <- factor(c("group1", "group2")) colData(object)$group <- group suppressMessages( x <- diffExpPerCluster( object = object, group = "group", numerator = "group2", denominator = "group1", caller = "edgeR" ) ) class(x)
#> [1] "list"
lapply(x, class)
#> $`0` #> [1] "DGELRT" #> attr(,"package") #> [1] "edgeR" #> #> $`1` #> [1] "DGELRT" #> attr(,"package") #> [1] "edgeR" #> #> $`2` #> [1] "DGELRT" #> attr(,"package") #> [1] "edgeR" #>