find_cnae_highlights: Returns a dataframe with job creation data on highlighted...

Description Usage Arguments Value Examples

View source: R/find_cnae_highlights.R

Description

Identifies best- or worst-performing CNAE sectors with respect to job creation and returns a dataframe with selected data.

Usage

1
2
3
4
5
6
find_cnae_highlights(
  df,
  positivos = TRUE,
  n_destaques = 5,
  filtrar_setor = FALSE
)

Arguments

df

A dataframe containing summarized job creation data. It must have columns setor and saldo.

positivos

logical. If FALSE, function returns worst-performing observations.

n_destaques

Number of observations to include as highlights.

filtrar_setor

FALSE or one of the 'big-five' IBGE sectors. If a sector is provided, the function returns only highlights for that specific sector.

Value

A dataframe with job creation data on CNAE sectors with best (or worst) performance.

Examples

1
2
3
4
5
6
7
8
## Not run: 
read_caged('CAGED_2018_10.txt') %>%
  prepare_caged() %>%
  filter(municipio_clean == 'RIBEIRAO PRETO') %>%
  compute_job_creation(setor, classe_cnae, .drop = FALSE) %>%
  find_cnae_highlights(setor == 'Serviços')

## End(Not run)

andremenegatti/cagedExplorer documentation built on July 1, 2020, 1:25 a.m.