sort_num_chr | R Documentation |
Just a convenience function often used to sort patient IDs by numerical value while being considered as factor though.
sort_num_chr(x, decreasing = F)
x |
vector of character or factor which represent numbers |
decreasing |
logical, sort decreasing |
character vector of sorted values
sort_num_chr(c("3", "4", "2"))
sort_num_chr(as.factor(c("3", "4", "2")))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.