datatype: datatype

Description Usage Arguments Value Examples

View source: R/validation.R

Description

"Bags" R vector data types (from class) into three bins: num = integer, numeric char = character, factor bool = logical Returns binned data type

Usage

1

Arguments

x

A vector

Value

A data type string

Examples

1
2
3
4
datatype(c(1,2,3)) == datatype(c(1L,2L,3L))
[1] TRUE
datatype(c('a','b')) == datatype(factor('a','b'))
[1] TRUE

Peder2911/Codder documentation built on Oct. 30, 2019, 9:40 p.m.