column_type_checker: Quick function for checking if a column is of the right type...

View source: R/column_type_checker.R

column_type_checkerR Documentation

Quick function for checking if a column is of the right type using data-masking

Description

Quick function for checking if a column is of the right type using data-masking

Usage

column_type_checker(data, column, type)

Arguments

data

Data Frame or Tibble object

column

Column you want to check

type

column's expected type

Value

a character vector

Examples

## Not run: 
check_text <- df %>% column_type_checker(text_var, "character")

if(check_text == "no") stop("Wrong type")


## End(Not run)

jpcompartir/JPackage documentation built on March 20, 2023, 4 a.m.