POSIXct values become numeric in reshape2 dcast

后端 未结 3 1790
长情又很酷
长情又很酷 2021-01-12 23:55

I\'m trying to use dcast from the latest reshape2 package (1.2.1) to denormalize a data frame (or data.table) where the value.var is a POSIXct type, but in the resulting dat

3条回答
  •  一生所求
    2021-01-13 00:16

    I just encountered this problem as well. I solved it by first coercing the date field into character, then dcast, and then converting back into a date.

提交回复
热议问题