Skip to contents

Performs a comprehensive audit of a VIGIAR data table against the expected schema, IBGE standards, and data quality rules. Returns a structured report suitable for regulatory compliance.

Usage

vigiar_auditar(dados, tabela = NULL, verbose = TRUE)

Arguments

dados

A VIGIAR data frame or tibble.

tabela

Table name for context.

verbose

If TRUE, prints detailed audit results.

Value

A list with audit sections: schema, ibge, temporal, units, coverage, checksums.

Examples

audit <- vigiar_auditar(pm25_rj_sample, tabela = "df_anual", verbose = FALSE)
audit$schema
#> $ok
#> [1] TRUE
#> 
#> $n_rows
#> [1] 15
#> 
#> $n_cols
#> [1] 7
#> 
#> $n_dup
#> [1] 0
#> 
#> $na_total
#> [1] 0
#> 
#> $na_pct
#> [1] 0
#> 
#> $details
#> character(0)
#>