alex.waterfall.plot {GRIN2} | R Documentation |
Generate Waterfall Plot of Lesion and Expression Data
Description
Creates a waterfall plot displaying gene expression levels grouped by lesion status for a selected gene.
Usage
alex.waterfall.plot(waterfall.prep, lsn.data, lsn.clrs = NULL, delta = 0.5)
Arguments
waterfall.prep |
Output from |
lsn.data |
Lesion data in GRIN-compatible format. |
lsn.clrs |
Named vector of colors for lesion types. If not provided, default colors will be automatically assigned using |
delta |
Spacing argument for the waterfall plot (default is 0.5). |
Details
This function generates a waterfall-style plot that visualizes gene expression across patients, grouped by lesion category. Patients are grouped by lesion type (sorted alphabetically), and within each group, expression levels are ordered from lowest to highest. The median expression level appears at the center of each group, allowing intuitive comparison between lesion categories.
Value
A side-by-side graphical representation of lesion status and gene expression for each patient, grouped by lesion type.
Author(s)
Abdelrahman Elsayed abdelrahman.elsayed@stjude.org, Stanley Pounds stanley.pounds@stjude.org
References
Cao, X., Elsayed, A. H., & Pounds, S. B. (2023). Statistical Methods Inspired by Challenges in Pediatric Cancer Multi-omics.
See Also
alex.prep.lsn.expr
, KW.hit.express
, alex.waterfall.prep
Examples
data(expr_data)
data(lesion_data)
data(hg38_gene_annotation)
# Prepare expression and lesion data
alex.data <- alex.prep.lsn.expr(expr_data, lesion_data,
hg38_gene_annotation, min.expr = 1, min.pts.lsn = 5)
# Run Kruskal Wallis test
alex.kw.results <- KW.hit.express(alex.data, hg38_gene_annotation, min.grp.size = 5)
# Prepare data for the WT1 gene
WT1.waterfall.prep <- alex.waterfall.prep(alex.data, alex.kw.results, "WT1", lesion_data)
# Generate waterfall plot for WT1
alex.waterfall.plot(WT1.waterfall.prep, lesion_data)