A GPU-accelerated volcano plot for differential-expression results. Points are rendered with WebGL (via regl-scatterplot) so hundreds of thousands to millions of genes/features stay interactive, while axes, threshold guides and gene labels are drawn as crisp vector overlays.
Usage
volcano(
data,
fc_threshold = 1,
p_threshold = 0.05,
point_size = 3,
opacity = 0.8,
colors = NULL,
x_label = "log2 fold change",
y_label = "-log10 p-value",
show_threshold_lines = TRUE,
label_top_n = 10,
theme = NULL,
width = NULL,
height = NULL,
element_id = NULL
)Arguments
- data
A data frame with numeric columns
x(log2 fold change) andy(-log10p-value). An optionallabelcolumn supplies gene names for tooltips and top-hit labels.- fc_threshold
Absolute log2 fold-change cutoff for calling a hit.
- p_threshold
P-value cutoff (applied on the
-log10scale).- point_size
Point radius in pixels.
- opacity
Point opacity in
[0, 1].- colors
Optional named list of hex colors for the three point classes:
up,downandns(not significant).NULL(the default) uses the component's built-in palette.- x_label, y_label
Axis titles.
- show_threshold_lines
Draw the fold-change / p-value threshold guides.
- label_top_n
Number of top up- and down-regulated genes to label.
- theme
Optional named list of theme overrides (colors, fonts, ...) merged over the component defaults in the browser.
NULLuses the default theme.- width, height
Widget dimensions (any valid CSS size).
- element_id
Optional explicit DOM id.