Contents
visualize$genome$reuse
Variant reuse across the genome (Manhattan track)
Manhattan-style genome track of variant reuse: each point is a harmonized variant at its genomic position, its height the number of models carrying it, on a pseudo-log10 y-axis. Peaks mark loci drawn on by many models. Chromosomes alternate shade and are labelled at their centres.
Usage
visualize.genome.reuse(
models,
palette = NULL,
raster = FALSE,
raster.args = list(),
point.size = 0.6,
point.alpha = 0.5,
height = 1,
theme = c("polygenius", "none")
)Arguments
| Argument | Description |
|---|---|
models | A PGSLibrary or a single PGS. Any other class, or an empty PGS library, aborts. Variants are allele-harmonized first, so a variant two models recorded with swapped alleles counts once; strand-ambiguous variants (A/T, C/G) are dropped. |
palette | Character vector of colours, a single colour or role/hue name, or NULL (default, the package colour). Sets the primary chromosome shade only -- the first colour is taken and the alternating shade stays neutral grey. |
raster | Logical scalar, default FALSE. Draw the points with ggrastr::geom_point_rast(), falling back to geom_point() with a warning when ggrastr is absent. Unlike [visualize$genome$manhattan](/reference/visualize-genome-manhattan/), this track never auto-enables it. |
raster.args | Named list, default list(). Extra arguments forwarded to ggrastr::geom_point_rast(), over a default raster.dpi = 300. |
point.size | Numeric scalar, default 0.6. Point size. |
point.alpha | Numeric scalar in [0, 1], default 0.5. Point alpha. |
height | Numeric scalar, default 1. Relative panel height when stacked. |
theme | One of "polygenius" (default), "none". Plot theme. "none" gives a bare theme_minimal() to style yourself; palette colors are applied either way. |
Value
A PolyGeniusGenomeTrack: the render spec (mark, data, params,
positions, height, label, build), build being the PGS library's
resolved genome build, or "unspecified" when its models disagree. Prints
as a standalone plot and composes with neither + nor draw(); stack it
with visualize$genome$stack.
Examples
visualize$genome$reuse(models, raster = TRUE)See Also
visualize$models$reuse for the same counts as a distribution rather than positioned; visualize$genome$coverage for the binned models-per-region companion.
Other visualize-genome:
visualize.genome.attribution(),
visualize.genome.concordance(),
visualize.genome.convergence(),
visualize.genome.coverage(),
visualize.genome.cumulativeWeight(),
visualize.genome.effects(),
visualize.genome.loci(),
visualize.genome.manhattan(),
visualize.genome.overview(),
visualize.genome.prs(),
visualize.genome.stack()