Collapse race down to the EPHT's allowable values: "W", "B", "O", "U"
Details
If there are any other values, they will be converted to "U". NULL
or
NA
values can be converted to "U" or left as `NA_character
Race Values
Character strings are converted to lowercase and stripped of any non-word characters. This is to ensure that the values are standardized before comparison.
Common values that get converted are:
white, caucasian -> "W"
blackorafricanamerican, black, africanamerican -> "B"
americanindianoralaskanative, americanindian, alaskanative -> "O"
asian -> "O"
nativehawaiianorotherpacificislander, nativehawaiian, otherpacificislander, pacificislander -> "O"
other -> "O"
unknown, unk, u -> "U"
See also
Other helpers:
collapse_ethnicity()
,
make_months_worse()
,
parse_health_outcome_id()