fix_factors | R Documentation |
This function goes through all columns of a data frame, and removes excess levels from columns of
class factor
, while leaving other columns unchanged. It is intended to be used after
filtering a data frame, so that excess levels do not cause errors or confusion in downstream
processes.
fix_factors(data)
data |
a data frame, with 0 or more columns of class |
a data frame of the same dimensions as data
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.