AutoCoerceClass: Automatically coerces a vector into an appropriate type.

View source: R/autocoerceclass.R

AutoCoerceClassR Documentation

Automatically coerces a vector into an appropriate type.

Description

Converts it to character, and then uses pattern matching to work out the most appropriate type.

Usage

AutoCoerceClass(x, stringsAsFactors = TRUE, max.value.labels = 12)

Arguments

x

A vector.

stringsAsFactors

logical: should character vectors be converted to factors?

max.value.labels

logical: only variables with value labels and at most this many unique values will be converted to factors. Ignored if stringsAsFactors is FALSE.


NumbersInternational/flipData documentation built on March 2, 2024, 10:52 a.m.