pathwayEnrichment: Pathway Enrichment

View source: R/runCIE.R

pathwayEnrichmentR Documentation

Pathway Enrichment

Description

Gets enriched pathways from the Reactome database using their analysis service

Usage

pathwayEnrichment(sigProtiens, numPathways=10)

Arguments

sigProtiens

A vector of protein names, intended to be used with the names column of the enrichment table returned by runCIE(). It is also suggested that you filter the results of enrichment by p-value so that you do not have insignificant protiens in your analysis.

numPathways

The number of pathways to pull from Reactome, defaults to '10

Value

A single data frame or list of dataframes consisting of the pathway, it's p-value and fdr from analysis using the Reactome analysis service, and the list of proteins given in sigProtiens found in the pathway.

Examples


## This example assumes that you have differential gene expression
## files ending in "edgeR.txt" in the current working directory and
## that the database directory is "../data".  The filtering
## parameters for ChIP in this instance are tailored for the
## experiment, namely restricting results to interactions observed
## in prostatic tissues.  For information about filtering the ChIP
## Atlas database, please visit our Wiki or review the
## documentation for filterChIPAtlas.

ChIP1ap <- filterChIPAtlas(1, NA, "auto", NA, "prostate", NA, NA, FALSE, databaseDir="../data")
files <- list.files("./", "egeR.txt")
dges <- lapply(files, function(x) {
   read.table(x, header=T, sep="\t") } )
names(dges) <- files
methods <-  "Fisher"
enrichment <- runCIE(NULL, NULL, DGEs=dges,
                     method = methods,
                     ents=ChIP1ap$filteredChIP.ents,
                     rels=ChIP1ap$filteredChIP.rels,
                     useFile=F, useMart=TRUE, useBHLH=TRUE,
                     martFN="../data/mart_human_TFs.csv",
                     BHLHFN="../data/BHLH_TFs.txt",
                     databaseDir="../data")

sigProt <- enrichment[[1]] %>%
  dplyr::filter(pval < 0.01) %>%
  dplyr::select(name)
sigProt <- sigProt$name
pathEnr <-pathwayEnrichment(sigProt)
View(pathEnr)

umbibio/CIE-R-Package documentation built on Sept. 26, 2023, 3:37 a.m.