View source: R/invert_contextual_grouping.R
| invert_contextual_grouping | R Documentation |
invert_contextual_grouping() transforms lightweight contextual
grouping definitions into a two-column table of group membership.
This is useful when contextual roots, resources, or candidate Record Set members are first declared as a named list but later need to be used in joins, rulebooks, or reconstruction workflows.
invert_contextual_grouping(x)
x |
A named list. Each list name identifies a contextual group, and each list element contains one or more members of that group. |
Convert a named list of contextual groupings into a long-form relational table.
The function performs a lightweight structural transformation.
It does not validate ontology semantics, enforce uniqueness, construct graph objects, or infer hierarchical relations.
The result is suitable for relational operations such as joins, filtering, contextual reconstruction, and candidate Record Set membership workflows.
A tibble with two columns:
Contextual grouping identifier.
Member associated with the contextual group.
as_value_key(), invert_value_key()
record_sets <- list(
conceptualisation = c(
"D:/_packages/alpha",
"D:/_markdown/alpha-methodology"
),
beta = c(
"D:/_packages/beta",
"D:/_packages/prebeta"
)
)
invert_contextual_grouping(record_sets)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.