Search a data.frame for 1:cardinality
relationships between a group
of columns (your identifiers) and all other columns.
checkColumnCardinality.Rd
Search a data.frame for 1:cardinality
relationships between a group
of columns (your identifiers) and all other columns.
Arguments
- df
A
data.frame
to search for 1:cardinality
mappings with the columns ingroup
.- group
A
character
vector of one or more column names to check the cardinality of other columns against.- cardinality
The cardinality of to search for (i.e., 1:
cardinality
) relationships with the combination of columns in group. Defaults to 1 (i.e., 1:1 mappings).- ...
Fall through arguments to data.table::
[
. For developer use. One use case is setting verbose=TRUE to diagnose slow data.table operations.
Value
A character
vector with the names of the columns with
cardinality of 1:cardinality
with the columns listed in group
.
Examples
df <- rawdata(exampleDataMapper)
checkColumnCardinality(df, group='treatmentid')
#> [1] "sampleid" "metadata"