| prep_groups | R Documentation |
Normalize and validate a grouping specification for use with group_imp().
Converts long-format or canonical list-column input into a validated
slideimp_tbl, enforcing set relationships, pruning dropped columns,
and optionally padding small groups.
prep_groups(
obj_cn,
group,
subset = NULL,
min_group_size = 0,
allow_unmapped = FALSE,
seed = NULL
)
obj_cn |
Character vector of column names from the data matrix
(e.g., |
group |
Specification of how features should be grouped for imputation. Accepts three formats:
|
subset |
Character vector of feature names to impute (default
|
min_group_size |
Integer or |
allow_unmapped |
Logical. If |
seed |
Numeric or |
Let A = obj_cn and B = the union of all feature and auxiliary
names in group. The function enforces A \subseteq B: every column in
the matrix must appear somewhere in the manifest.
Pruning: Elements in B but not in A (e.g., QC-dropped probes)
are silently pruned from each group.
Dropping: Groups left with zero features after pruning are
removed entirely with a diagnostic message.
A data.frame of class slideimp_tbl containing:
group: Original group labels (if provided) or sequential group labels.
feature: A list-column of character vectors (feature names).
aux: A list-column of character vectors (auxiliary names).
parameters: A list-column of per-group configuration lists.
group_imp()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.