You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed that setorder is case-sensitive in a different way to base::order
DT<- data.table(x= c("a", "A", "B", "b"), y=1:4)
DF<- as.data.frame(DT)
# ordered by case, then alphabetically and capital letters occur before lower-case lettersDT[order(x)]
# x y# 1: A 2# 2: B 3# 3: a 1# 4: b 4# in alphabetical order first, then case-sensitively (and lower-case first)DF[order(DF$x), ]
# x y# 3 a 1# 1 A 2# 4 b 4# 2 B 3
If this is intended behaviour, I believe it should be added to the documentation for ?setorder.
The text was updated successfully, but these errors were encountered:
FWIW, I saw data.table always reorders in C-locale in the documentation (before raising this issue) but didn't realize it had that effect. (I thought it was just a comment about performance.)
I noticed that
setorder
is case-sensitive in a different way tobase::order
If this is intended behaviour, I believe it should be added to the documentation for
?setorder
.The text was updated successfully, but these errors were encountered: