Description Usage Arguments Value Examples
This function supports any combination of numeric x-y variables to plot from fedup results. The list outputted by runFedup must first be converted to a data.frame before plotting (see examples for sample use).
1 2 3 4 5 6 7 8 9 10 11 12 13 |
df |
(data.frame) table with fedup results generated via runFedup |
xVar |
(char) x-axis variable (must be a column value in |
yVar |
(char) y-axis variable (must be a column value in |
xLab |
(char) x-axis label (default |
yLab |
(char) y-axis label (default NULL) |
pTitle |
(char) plot title (default NULL) |
fillVar |
(char) point fill variable (default NULL) |
fillCol |
(char) point fill colours (default NULL) |
fillLab |
(char) point fill label (default |
sizeVar |
(char) point size variable (default NULL) |
sizeLab |
(char) point size label (default |
Object returned from ggplot with the enrichment dot plot.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | # Load example data
data(geneDouble)
data(pathwaysGMT)
# Load external libraries
suppressMessages(library(dplyr))
suppressMessages(library(tidyr))
# Run fedup
fedupRes <- runFedup(geneDouble, pathwaysGMT)
# Prepare dataframe from fedup results
fedupPlot <- fedupRes %>%
bind_rows(.id = "set") %>%
separate(col = "set", into = c("set", "sign"), sep = "_") %>%
subset(qvalue < 0.01) %>%
mutate(log10qvalue = -log10(qvalue)) %>%
mutate(pathway = gsub("\\%.*", "", pathway)) %>%
as.data.frame()
# Plot
p <- plotDotPlot(
df = fedupPlot,
xVar = "log10qvalue",
yVar = "pathway",
xLab = "-log10(qvalue)",
fillVar = "sign",
fillLab = "Genetic interaction",
fillCol = c("#0077f1", "#fcde24"),
sizeVar = "fold_enrichment",
sizeLab = "Fold enrichment"
)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.