Re-exported functions from other packages
re-exports.Rd
enrichit::EnrichIt()
(exported as RunEnrichment) - Enrichment analysisenrichit::ParseGMT()
- Parse GMT file
Usage
RunEnrichment(
userlist,
dbs,
method = ifelse(tolower(style[1]) == "enrichr", "fisher", "hypergeometric"),
use_matched_only = ifelse(tolower(style[1]) == "enrichr", FALSE, TRUE),
padjust_method = c("BH", "bonferroni", "holm", "hochberg", "hommel", "BY", "fdr"),
background = NULL,
style = c("enrichr", "Enrichr", "clusterProfiler", "ClusterProfiler",
"clusterprofiler"),
return_all = FALSE
)
ParseGMT(gmtfile, swap_name_desc_if_needed = TRUE)
VizEnrichment(
data,
top_term = NULL,
plot_type = c("bar", "dot", "lollipop", "network", "enrichmap", "wordcloud",
"comparison"),
x_by = NULL,
size_by = NULL,
fill_cutoff_name = NULL,
fill_name = NULL,
character_width = 50,
expand = NULL,
word_type = c("term", "feature"),
split_by = NULL,
split_by_sep = "_",
facet_by = NULL,
facet_scales = NULL,
group_by = NULL,
group_by_sep = "_",
metric = "p.adjust",
cutoff = NULL,
palette = "Spectral",
xlab = NULL,
ylab = NULL,
...
)
Arguments
- userlist
Vector of user-provided genes
- dbs
List of gene sets or paths to GMT files It can be a vector of database names. You can set the names of the vector, which will be used as the database names. Otherwise a list is expected, where each element is a database (e.g. parsed from a gmt file). If a database is given directly (without a name), the expression of this argument will be used as the database name.
- method
Method for computing p-value, either "fisher" or "hypergeometric" When
style
is "enrichr", the method defaults to "fisher". Whenstyle
is "clusterProfiler", the method defaults to "hypergeometric".- use_matched_only
Logical, whether to use only matched genes against the gene sets. This will affect the number of genes in the user list when computing the p-value. By default, when
style
is "enrichr", this is set to FALSE. Whenstyle
is "clusterProfiler", this is set to TRUE.- padjust_method
Method for adjusting p-values, either "BH", "bonferroni", "holm", "hochberg", "hommel", "BY", "fdr"
- background
Vector of all genes in the universe or a number of genes in the universe. If NULL, the number of genes in the gene set will be used. For "enrichr", the default is 20,000. For "clusterProfiler", the default is the number of unique genes in the gene set. Note that for "enrichr", if a vector is given, the length of it will be used, no checking will be done to see if userlist and genes from dbs are in the vector.
- style
Style of the output, either "enrichr" or "clusterProfiler"
- return_all
Logical, whether to return all results (all gene sets in dbs) or only those with at least one gene in the user list.
- gmtfile
Path to the GMT file
- swap_name_desc_if_needed
Logical, whether to swap name and description fields. They will be swapped only if:
swap_name_desc_if_needed
isTRUE
; andThe descriptions are not empty; and
The descriptions are shorter than the names; and
The descriptions are not ID-like (i.e., hsa00001, or 123456).
- data
A data frame with enrichment results generated by
clusterProfiler
,enrichR
, orenrichit
.- top_term
Number of top terms to show in the plot. Default is 6 for all plots except "enrichmap" which is 100.
- plot_type
Type of plot to generate. Options are "bar", "dot", "lollipop", "network", "enrichmap", "wordcloud", "comparison".
- x_by
A character vector of column names to use for the x-axis. Default is NULL. Works only for "dot" and "lollipop".
- size_by
A character vector of column names to use for the size of the points. Default is NULL. Works only for "comparison", "dot" and "lollipop".
- fill_cutoff_name
The legend name for the terms above the cutoff value. Default is NULL. Works only for "comparison", "dot" and "lollipop".
- fill_name
The legend name for the metric. Default is NULL. Works only for "comparison", "dot" and "lollipop".
- character_width
The width of the terms in the plot. Default is 50. When the terms are too long, they will be wrapped to fit the width.
- expand
A numeric vector of length 1, 2 or 4 to expand the plot. Default is NULL. Works only for "bar" plot. See also plotthis::BarPlot.
- word_type
The type of word to show in the wordcloud. Options are "term" and "feature". Default is "term". Works only for "wordcloud".
- split_by
A character vector of column names to split the plots. Default is NULL.
- split_by_sep
A character to separate the split_by column names. Default is "_".
- facet_by
A character vector of column names to facet the plots. Default is NULL.
- facet_scales
The facet scales. Default is NULL.
- group_by
A character vector of column names to group the terms. Default is NULL. Works only for "comparison" plot.
- group_by_sep
A character to concatenate the group_by columns when there are multiple columns. Default is "_". Works only for "comparison" plot.
- metric
The column name to use for the metric. Default is "p.adjust".
- cutoff
The cutoff value to the metric to mark the tems on the plot. Default is NULL. Note that the terms are not filtered by this value. Use
top_terms
to filter the terms. When specified:'bar' plot will show a line at the cutoff value
'dot' plot will show gray dots for the terms above the cutoff value
'lollipop' plot will show gray dots for the terms above the cutoff value
'comparison' plot will show gray dots for the terms above the cutoff value
has no effect on 'network', 'enrichmap', and 'wordcloud' plots
- palette
The color palette to use for the plot. Default is "Spectral". See plotthis::show_palettes for available palettes.
- xlab
The x-axis label. Default is NULL.
- ylab
The y-axis label. Default is NULL.
- ...
Other arguments passed to the specific plot function.
For "bar",
plotthis::BarPlot()
.For "dot",
plotthis::DotPlot()
.For "lollipop",
plotthis::LollipopPlot()
.For "network",
plotthis::EnrichNetwork()
.For "enrichmap",
plotthis::EnrichMap()
.For "wordcloud",
plotthis::WordCloudPlot()
.For "comparison",
plotthis::DotPlot()
.