Look up rows of the USA location table corresponding to the entries of a given vector.
Source:R/recode_locations.R
location_lookup.Rd
Get the rows of us_location_table corresponding to a given location vector and format, with repeats possible
Arguments
- location_vector
vector of location values
- location_input_format
format in which the location vector is coded. Permitted formats are
"abbr"
(state/territory or nation two letter USPS abbreviation),"hub"
(legacy 2-digit FIPS code for states and territories,US
for the USA as a whole), and"long_name"
(full English name for jurisdiction).- location_output_format
Return only this column of the output table, if it is provided. Otherwise return the whole table. Default
NULL
(return all columns). or nation two letter USPS abbreviation),"hub"
(legacy 2-digit FIPS code for states and territories,US
for the USA as a whole), and"long_name"
(full English name for jurisdiction).
Value
the corresponding rows of the us_location_table matching the location vector, with repeats possible.