enrich {CTDquerier} | R 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

    data("gala")
    air <- query_ctd_chem( terms = "Air Pollutants" )
    hgnc_universe <- readRDS(paste0(path.package("CTDquerier"),"/extdata/universe.RDS"))
    enrich(gala, air, hgnc_universe)

[Package CTDquerier version 2.2.0 Index]