plotGODot | R Documentation |
Visualize GO enrichment test result in dot plot
plotGODot(
result,
group = NULL,
query = c("Up", "Down"),
pvalThresh = 0.05,
n = 20,
termIDMatch = "^GO",
colorPalette = "E",
colorDirection = 1,
xlab = "-log10(P-value)",
ylab = "Term name",
...
)
result |
Returned list object from |
group |
Character vector of group names, must be available in
|
query |
A single string selecting from which query to show the result.
Choose from |
pvalThresh |
Numeric scalar, cutoff for p-value where smaller values are
considered as significant. Default |
n |
Number of top terms to be shown, ranked by p-value. Default
|
termIDMatch |
Regular expression pattern to match the term ID. Default
|
colorPalette , colorDirection |
Viridis palette options. Default
|
xlab , ylab |
Axis title for x and y axis. Default
|
... |
Arguments passed on to
|
A ggplot object if only one group or a list of ggplot objects.
defaultCluster(pbmc) <- pbmcPlot$leiden_cluster
# Test the DEG between "stim" and "ctrl", within each cluster
result <- runPairwiseDEG(
pbmc,
groupTest = "stim",
groupCtrl = "ctrl",
variable1 = "dataset",
splitBy = "defaultCluster"
)
# Setting `significant = FALSE` because it's hard for a gene list obtained
# from small test dataset to represent real-life biology.
if (requireNamespace("gprofiler2", quietly = TRUE)) {
go <- runGOEnrich(result, group = "0.stim", splitReg = TRUE, significant = FALSE)
# The toy example won't have significant result.
plotGODot(go)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.