clean_table: Remove columns filled only with NA (missing value)

View source: R/clean_table.R

clean_tableR Documentation

Remove columns filled only with NA (missing value)

Description

Remove columns filled only with NA (missing value)

Usage

clean_table(df)

Arguments

df

the dataframe to be cleaned

Value

a dataframe without columns containing only NA

Examples


library(tidyverse)

idbank_empl =
 get_idbank_list("EMPLOI-SALARIE-TRIM-NATIONAL") %>% #employment
 mutate(title = get_insee_title(idbank)) %>%
 separate(title, sep = " - ", into = paste0("title", 1:5), fill = "right") %>%
 clean_table()


insee documentation built on Sept. 18, 2022, 1:08 a.m.