util_recode | R Documentation |
Map a vector of values based on an assignment table
util_recode(values, mapping_table, from, to, default = NULL)
values |
vector the vector |
mapping_table |
data.frame a table with the mapping table |
from |
character the name of the column with the "old values" |
to |
character the name of the column with the "new values" |
default |
character either one character or on character per value,
being used, if an entry from |
the mapped values
dplyr::recode
Other mapping:
util_map_all()
,
util_map_by_largest_prefix()
,
util_map_labels()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.