[datatable-help] Integration with magrittr

Michael Smith my.r.help at gmail.com
Tue Jun 30 03:06:42 CEST 2015


All,

I love data.table and I also love magrittr. However, some things don't 
work, e.g.

DT <- data.table(a = 1:3, b = 4:6)
DT[, a %<>% `*`(2)]    # instead of DT[, a := a %>% `*`(2)]

Is there some way to make it work or am I missing something? I 
understand it's because how data.table is essentially a DSL and parses 
things in its own ways. Is there a workaround or should I post a feature 
request?

Thanks,
M


More information about the datatable-help mailing list