Answers for "how to convert the variables into a factor in r"

R
1

How to Convert a Factor in R

> directions <- c("North", "East", "South", "South")
> directions.factor <- factor(directions)
> directions.factor
[1] North East South South
Levels: East North South
Posted by: Guest on December-21-2020

Code answers related to "how to convert the variables into a factor in r"

Browse Popular Code Answers by Language