gagolews / stringi

Fast and portable character string processing in R (with the Unicode ICU)
https://stringi.gagolewski.com/
Other
304 stars 44 forks source link

numeric collation - negative numbers not supported #462

Closed gagolews closed 2 years ago

gagolews commented 3 years ago

As mentioned in https://github.com/tidyverse/stringr/issues/402, negative numbers are not handled correctly

stringi::stri_sort(c('-1', '0', '-10', '5', '3.14'), numeric=TRUE)
## [1] "-1"   "-10"  "0"    "3.14" "5" 

TODO: This should be mentioned in the manual