
Generate volcano plot(s) from differential expression results
Source:R/PlottingUtils.R
plotVolcano.RdThis function takes the output from function runDE and creates volcano
plots for each indicated split.
Usage
plotVolcano(
input,
alpha = 0.05,
lfc_threshold = 0,
use_splits = NULL,
title = NULL,
subtitle = NULL,
n_max_label = 10,
label_features = NULL,
center = TRUE
)Arguments
- input
Output from function
runDEor a list containing (at minimum) a dataframe named "DE_results" including columns:- feature
Feature identifiers (character).
- lfc
Log2 fold change values (numeric).
- padj
Adjusted p-values (numeric).
- split
Grouping variable used to subset results (character or factor).
- alpha
A numeric value indicating the significance level used for permutation test comparisons of the number of differentially expressed features. Defaults to 0.05.
- lfc_threshold
A numeric value indicating the minimum absolute value log fold change for a feature to be counted as a "hit". Default = 0 disregards log fold change when counting hits.
- use_splits
A character string or vector containing the names of splits to use. Defaults to
NULL, which will try all splits.- title
Character string indicating the plot title. Default =
NULLsets a title automatically for each split.- subtitle
Character string indicating the plot subtitle. Default =
NULLautomatically generates a subtitle describing the DE method used.- n_max_label
A numeric value indicating how many of the top significant DE features to label. Defaults to 10.
- label_features
An optional vector containing feature names to label. Default =
NULLwill label top significant DE features.- center
A Boolean value indicating whether to center the x-axis at 0. Defaults to
TRUE.