Learn R Programming

censable (version 0.0.5)

collapse4_pop: Collapse Population Race Categories into 4 Categories

Description

Collapses Other, AIAN, Asian, NHPI, and Two+ into other.

Usage

collapse4_pop(.data, prefix = "pop_")

Value

.data with columns collapsed

Arguments

.data

tibble, data.frame, or sf tibble

prefix

Default is pop_. The prefix for the race categories.

Examples

Run this code
data(mt_county)
mt_county <- mt_county %>% collapse4_pop()

Run the code above in your browser using DataLab