Skip to contents

Checks that municipality codes are 6- or 7-digit integers within the valid Brazilian range (110001-530010).

Usage

vigiar_validar_ibge(dados, col_codigo = "cod_municipio")

Arguments

dados

A data frame.

col_codigo

Name of the column containing IBGE codes.

Value

The data frame (unchanged), with a warning on invalid codes.

Examples

vigiar_validar_ibge(data.frame(cod_municipio = c(330455L, 355030L)))
#>   cod_municipio
#> 1        330455
#> 2        355030