term_enrichment: term_enrichment

Description Usage Arguments Value Examples

View source: R/lib_enrichment.R

Description

term_enrichment evaluates the input gene list for enrichment within each of the annotation resources. This differs from the enrichment_symbols function which evaluates the gene list for enrichment against all of the annotation resources grouped together.

Usage

1
2
3
term_enrichment(geneset, resources = resources.default,
  report_resources_separately = FALSE, verbose = TRUE, all_symbols = NA,
  filter_to_intersection = FALSE, ...)

Arguments

geneset

vector of gene symbols to be evaluated

resources

list containing the reference gene sets to test for enrichment

report_resources_separately

logical (default FALSE) flag to report enrichments seperately for each requested resource, or to combine them and produce FDR adjustment across the combined set

verbose

print the top results for each annotation resource

all_symbols

the background/global set of gene symbols (study dependent; we provide all protien coding genes as a default)

filter_to_intersection

[FALSE] should the background and foreground genesets be subsetted to one another?

...

further arguments are passed on to enrichment_symbols()

Value

results matrix of input gene list compared to active gene sets. Q value is calculated within each of the active gene sets.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Check if there is enrichment for any "Hallmark" functions within a input set of genes
require(RITANdata)
myGeneSet <- c('BRCA1','RAD51C','VAV1','HRAS','ABCC1','CYP1B1','CYP3A5')
e <- term_enrichment(myGeneSet, "MSigDB_Hallmarks")
print( e[1:2, -6] )

## Not run: 
term_enrichment(geneset = vac1.day0vs31.de.genes)
term_enrichment(geneset = vac1.day0vs31.de.genes, resources = "MSigDB_Hallmarks")
vac1.day0v31.enrichment <- term_enrichment(geneset = vac1.day0vs31.de.genes, verbose = FALSE)

## End(Not run)

RITAN documentation built on Nov. 8, 2020, 8:16 p.m.