Replace two or more named categories of any column with a new joint category name
Source:R/output_trips.R
process_rename_category.Rd
The function process_rename_category takes a tibble as input and replaces all occurrences of the specified categories in a column with another name provided in united_name.
Usage
process_rename_category(
trips_table,
unite_template = character(0),
united_name = "united",
column = "main_mode"
)
Arguments
- trips_table
tibble of output_trips (from
read_output_trips
)- unite_template
vector of character strings, changes names of chosen categories to a new specified name (i.e. drtNorth and drtSouth to drt)
- united_name
character string, specifies the name of the united categories
- column
tibble column name, which will be used in occurrences renaming