This function loads a specific label data set that can be used to label five or three-digit ZIP codes in a data frame.
Arguments
- source
A required character scalar; specifies the source of the label data. The only supported sources are
'UDS'(default) and'USPS'.- type
A required character scalar; one of either
'zip3'or'zip5'. The'zip3'type is only available from the'USPS'source, while the'zip5'type is available from'UDS'.- include_scf
A logical scalar required when
source = 'USPS'andtype = 'zip3'; specifying whether to include the SCF (Sectional Center Facility) ID in the output. The default isFALSE.- vintage
A required character or numeric scalar; specifying the date for
source = 'USPS'or the year of the data forsource = 'UDS'. Thezip_load_labels_list()function can be used to see available date values forsource = 'USPS'.
Details
Labels are approximations of the actual location of a ZIP Code. For five-digit ZIP Codes, the city and state may or may not correspond to an individuals' mailing address city (since multiple cities may be accepted as valid by USPS for a particular ZIP Code) or state (since ZIP Codes may cross state lines).
For three-digit ZIP Codes, the area and state may or may not correspond to
an individuals' mailing address state (since SCFs cover multiple states).
For example, the three digit ZIP Code 010 covers Western Massachusetts
in practice, but is assigned to the state of Connecticut.