cep_to_state: Determine the state of a given CEP postal code

View source: R/cep_to_state.R

cep_to_stateR Documentation

Determine the state of a given CEP postal code

Description

Zips codes in Brazil are known as CEP, the abbreviation for postal code address. CEPs in Brazil are 8 digits long, with the format 'xxxxx-xxx'.

Usage

cep_to_state(cep)

Arguments

cep

A character string with 8 digits in the format "xxxxxxxx", or with the format 'xxxxx-xxx'.

Value

A character string with a state abbreviation.

Examples


uf <- cep_to_state(cep = '69900-000')

# Or:
uf <- cep_to_state(cep = '69900000')


geobr documentation built on Sept. 11, 2024, 6:58 p.m.