Learn R Programming

sqlutils (version 1.2)

recodeColumns: Recodes factors with more than maxLevels to characters.

Description

Recodes factors with more than maxLevels to characters.

Usage

recodeColumns(df, maxLevels = 20)

Arguments

df
the data frame to recode.
maxLevels
the maximum number of levels a factor can have before being converted to a character.