R/disease2pathway.R

Defines functions disease2path

Documented in disease2path

#' Enrichment of pathways associated with drug combinations
#'
#' @param druglist_meshid Drug combination of meshid
#'
#' @return data.frame
#'
#'
#' @importFrom clusterProfiler enrichGO
#'
#' @export


disease2path <- function(druglist_meshid) {
  genelist <- drug2gene(druglist_meshid)

  ego <- clusterProfiler::enrichGO(
    gene = genelist$GENEID,
    keyType = "ENTREZID",
    OrgDb = "org.Hs.eg.db",
    ont = "ALL",
    pAdjustMethod = "BH",
    pvalueCutoff = 0.01,
    qvalueCutoff = 0.01
  )
  return(ego@result)

}
ymwang233/DEpath documentation built on April 10, 2021, 1:36 p.m.