Skip to content

Problems with text indexing #2114

@JBreidaks

Description

@JBreidaks

I have vector with characters:
y <- c('B','Ā','Č','D','Ē','E')

When I sort using order for vector
y2 <- y[order(y)]
y2

[1] "Ā" "B" "Č" "D" "E" "Ē"
y2 <- data.table(y = y2)

If I make vector as data.table and sort with setkeyv then can not get the same result as y2.

test2 <- data.table(y)
setkeyv(test2, "y")
test2

identical(y2, test2)

Maybe can give some solution for this situation?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions