enrich-methods: Method to perform enrichment analysis using two 'CTDdata'...

enrichR Documentation

Method to perform enrichment analysis using two CTDdata objects

Description

This methods performs a fisher test using the genes in two objects of class CTDdata. The object in 'x' is used as source while the object on 'y' is used as universe. When object 'x' corresponds to an object created with query_ctd_gene, the used genes are the found terms in CTDbase. In the other cases (chemicals and disease CTDdata), the genes from the 'gene interactions' table are used. If universe is missing, all genes in CTDbase are used as universe.

Usage

enrich(x, y, universe, use = "curated", warnings = TRUE, ...)

Arguments

x

Object of class CTDdata.

y

Object of class CTDdata.

universe

Vector of strings corresponding to the genes to be used as universe.

use

(default: "curated") It can take values "curated" or "all" to filter or not filter for curated the genes into the CTDdata objects.

warnings

(default: TRUE).

...

NOT USED

Value

A list with class htest. Check fisher.test for more information.

Examples

# Example in a tryCatch, since we are performing a connection to a server we might
# get a refused connection due to a server rejection. Evaluate the recieved HTTP 
# message to understand if the server is not available or if your IP adress is temporarly restricted
tryCatch({
data("gala")
air <- query_ctd_chem( terms = "Air Pollutants" )
hgnc_universe <- readRDS(paste0(path.package("CTDquerier"),"/extdata/universe.RDS"))
enrich(gala, air, hgnc_universe)
}, error = function(w){NULL})

isglobal-brge/CTDquerier documentation built on Oct. 6, 2022, 1:18 p.m.