plotEnrich {enrichR} | R Documentation |
plotEnrich
Description
Visualise a Enrichr output as barplot
Usage
plotEnrich(
df,
showTerms = 20,
numChar = 40,
y = "Count",
orderBy = "P.value",
xlab = NULL,
ylab = NULL,
title = NULL
)
Arguments
df |
(Required). A single data.frame from a list of Enrichr output. |
showTerms |
(Optional). Number of terms to show. Default is |
numChar |
(Optional). A single integer. Default is |
y |
(Optional). A character string. Default is |
orderBy |
(Optional). A character string. Default is
|
xlab |
(Optional). A character string. Default is |
ylab |
(Optional). A character string. Default is |
title |
(Optional). A character string. Default is |
Details
Visualise Enrichr result from a selected gene-set library as barplot.
Value
A ggplot
plot object
Author(s)
I-Hsuan Lin i-hsuan.lin@manchester.ac.uk
See Also
Examples
# data(input) # Load example input genes
# dbs <- c("GO_Molecular_Function_2023", "GO_Cellular_Component_2023",
# "GO_Biological_Process_2023")
# if (getOption("enrichR.live")) {
# enriched <- enrichr(input, dbs)
# print(head(enriched[[1]]))
# # Plot top 20 terms from "GO_Biological_Process_2023" and ordered by P-value
# plotEnrich(enriched[[3]], showTerms = 20, numChar = 50, y = "Count",
# orderBy = "P.value")
# }