split_title: Split the title column in several columns

Description Usage Arguments Details Examples

View source: R/split_title.R

Description

Split the title column in several columns

Usage

1
split_title(df, title_col_name, n_split = "max", lang = "en")

Arguments

df

a dataframe containing a title column

title_col_name

the column name to be splitted, if missing it will be either TITLE_EN

n_split

number of new columns, by default the maximum is chosen

lang

by default it returns an English title (its default value is "en"), any other value returns a French title

Details

The number of separators in the official INSEE title can vary and is not normalized. Beware all title columns created may not be a cleaned dimension label.

Examples

1
2
3
4
5
# quarterly payroll enrollment in the construction sector
data_raw = get_insee_idbank("001577236")

data = data_raw %>%
  split_title(lang = "fr")

hadrilec2/insee documentation built on Aug. 10, 2020, 1:53 a.m.