Description Usage Arguments Details
Enhance a target data.frame that has one column of keys or IDs from the key-value pair that exists in two columns of a source data.frame.
1 2 3 4 5 6 7 8 | enhance_from_keys(
target_df,
source_key_col,
source_prop_col,
target_key_col_name,
target_prop_name,
remove_target_key_col = TRUE
)
|
target_df |
The data.frame to be enhanced. |
source_key_col |
The column in the reference data.frame containing the keys/IDs, passed as a vector, eg. Employees$id |
source_prop_col |
The column in the reference data.frame containing the values, passed as a vector, eg. Employees$name |
target_key_col_name |
The name of the column in the target data.frame containing the keys/IDs, passed as a string, eg. "Employee_ID" |
target_prop_name |
The name for the new column to be added to the target data.frame containing the values, passed as a string, eg. "Employee_Name" |
This handles a join to enhance one data.frame that contains a column of keys/IDs from another data.frame that contains columns of key-value pairs. For example, to lookup names by reference to ID numbers.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.