| .to_factor_safely | R Documentation |
An internal helper function that converts a character vector to a factor, ensuring the level order is based on the first appearance of each element. If the input is not a character vector, it's returned unchanged.
.to_factor_safely(x)
x |
A vector from a design specification. |
A factor with levels in order of appearance, or the original object.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.