Factor coercion
Coercion functions for creating factors from other existing objects.
as.factor(x, ...) as.ordered(x, ...)
x |
A vector of data. |
... |
Other arguments passed on to methods. |
These functions override non-generic factor coercion functions provided in base so that packages can provide methods for different data types. The default methods call the base versions.
For as.factor()
, a factor. For as.ordered()
,
an ordered factor.
as.factor()
No methods found in currently loaded packages.
as.ordered()
No methods found in currently loaded packages.
as.factor(letters[1:5]) as.ordered(letters[1:5])
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.