abbr2state: Convert state names to abbreviations and back again

Description Usage Arguments Value Author(s) See Also Examples

Description

Two utility functions. One converts state names to the state abbreviations, and the second does the opposite.

Usage

1
2
3

Arguments

state

A vector of state name, where there is a little fuzzy matching.

abbr

A vector of state abbreviation.

Value

Returns a vector of the same length with the corresponding state names or abbreviations.

Author(s)

David Diez

See Also

county, countyComplete

Examples

1
2
3
4
5
state2abbr("Minnesota")
abbr2state("MN")

#_____ Some Spelling/Capitalization Errors Okay _____#
state2abbr("mINnesta")

JECheadle/RSOC317L documentation built on May 15, 2019, 4:02 a.m.