Skip to content

as.xts.data.table is limited to numeric data types, but this is not an xts limitation #5268

@ethanbsmith

Description

@ethanbsmith

xts allows columns to have any type, as long as the columns are all the same type (as its really a matrix under the hood)

for example, you can have character columns:
xts(x = cbind(letters, LETTERS), order.by = Sys.Date() + (1:26))

logicals:
xts(x = c(T,F), order.by = Sys.Date() + (1:2))

as.xts.data.table currently only allows conversion for numeric columns. it should follow the same rules as xts and support any type

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions