Component gallery coloured by canonically aligned sample metadata
Source:R/14-stage1-plots.R
plot_components.RdShows the sample-coordinate distribution for each of the first
n_components components as stored density and rug panels in decomposition
order. Metadata are read from MAE-level colData and aligned to the
selected assay through its canonical sampleMap; row position is never
treated as sample identity.
Details
Categorical and continuous metadata colour the rugs while retaining the stored overall density. The gallery does not calculate association scores or rank components; those responsibilities belong to the metadata atlas and proposal workflow.
Examples
std <- synthetic_control(n = 40L, p = 500L, K = 2L, signal = 30, seed = 1L)
ctor <- get_strategy("Decomposer", "hogsvd_averaged")
std2 <- suppressWarnings(decompose(ctor(), std))@value
plot_components(std2, colour_by = "planted_group")