degIntersection: Intersection of differentially expressed genes

degIntersectionR Documentation

Intersection of differentially expressed genes

Description

Intersection of differentially expressed genes

Usage

degIntersection(object, ...)

## S4 method for signature 'DESeqAnalysis'
degIntersection(
  object,
  i = NULL,
  alphaThreshold = NULL,
  baseMeanThreshold = NULL,
  lfcThreshold = NULL,
  direction = c("up", "down"),
  return = c("matrix", "count", "ratio", "names")
)

## S4 method for signature 'DESeqAnalysisList'
degIntersection(
  object,
  i = NULL,
  alphaThreshold = NULL,
  baseMeanThreshold = NULL,
  lfcThreshold = NULL,
  direction = c("up", "down"),
  return = c("matrix", "count", "ratio", "names")
)

## S4 method for signature 'DESeqResultsList'
degIntersection(
  object,
  direction = c("up", "down"),
  alphaThreshold = NULL,
  baseMeanThreshold = NULL,
  lfcThreshold = NULL,
  return = c("matrix", "count", "ratio", "names")
)

Arguments

object

Object.

i

character, numeric, or NULL. Names or range of results. If set NULL, include all results per object. When passing in multiple objects, specify the desired results as a list with length matching the number of input objects, containing either character or numeric corresponding to each object.

alphaThreshold

numeric(1) or NULL. Adjusted P value ("alpha") cutoff. If left NULL, will use the cutoff defined in the object.

baseMeanThreshold

numeric(1) or NULL. Base mean (i.e. average expression across all samples) threshold. If left NULL, will use the cutoff defined in the object. Applies in general to DESeq2 RNA-seq differential expression output.

lfcThreshold

numeric(1) or NULL. Log (base 2) fold change ratio cutoff threshold. If left NULL, will use the cutoff defined in the object.

direction

character(1). Include "up" or "down" directions. Must be directional, and intentionally does not support "both".

return

character(1).

  • "matrix": ⁠logical matrix⁠; Intersection matrix.

  • "count": integer; Number of times the gene is significant across contrasts.

  • "ratio": numeric; The ratio of how many times the gene is significant across contrasts.

  • "names": character; Names of genes that intersect across all contrasts defined. Input of specific contrasts with i argument is recommended here.

...

Passthrough arguments to DESeqResultsList method.

Value

integer. Integer denoting the number of intersections, sorted from highest to lowest. Gene identifiers are defined as the names.

Note

Updated 2023-10-04.

Examples

data(deseq)

## DESeqAnalysis ====
mat <- degIntersection(deseq, return = "matrix")
print(class(mat))
print(head(mat))

count <- degIntersection(deseq, return = "count")
print(class(count))
print(head(count))

ratio <- degIntersection(deseq, return = "ratio")
print(class(ratio))
print(head(ratio))

names <- degIntersection(deseq, i = c(1L, 2L), return = "names")
print(class(names))
print(head(names))

## DESeqAnalysisList ====
object <- DESeqAnalysisList(list("object1" = deseq, "object2" = deseq))
print(object)

steinbaugh/DESeqAnalysis documentation built on April 1, 2024, 8:30 a.m.