Description Usage Arguments Value Examples
View source: R/convert_factor_to_numeric.R
Convert a factor type to a numeric type levels() gets the factor levels as characters as.numeric() converts the factor levels to numeric subsetting the factor column by as.numeric(levels()) gives the numeric form of the factor column
1 |
x |
A vector of type factor |
A vector of type numeric
1 2 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.