Convert Ethnicity to Numeric Code
Arguments
- ethnicc
Ethnic character
Value
the standard yspec numeric value for the inputted Ethnic character
See also
Other demographics:
is_american_native(),
is_asian(),
is_black(),
is_female(),
is_hispanic_or_latino(),
is_not_hispanic_or_latino(),
is_other(),
is_pacific_islander(),
is_unspecified(),
is_white(),
racen(),
sexf()
Examples
ethnicn("HISPANIC OR LATINO") # 1
#> [1] 1
ethnicn("NOT HISPANIC OR LATINO") # 0
#> [1] 0
ethnicn("UNKNOWN") # default missing value
#> [1] -999