I have a vector of strings in R that follow this format: 1:A
. So let's say I have a vector with strings
x = c("1:A", "201:A", "2:A")
I want to sort through this vector so it becomes
["1:A" "2:A" "201:A"]
Is there a function that is capable of this in R? I have tried
mixedsort(x, decreasing = FALSE)
from the gtools
library, but it still doesn't seem to completely work very well when this vector is scaled up to include the letter B
as well. Any ideas?