:= isn't actually defined as a function by data table., it only works within a call to [.data.table as the j argument, and is recognised by parsing the j expression (within the function call). This I would think it would need to be a feature request.
> On 30 Jun 2015, at 11:07 am, Michael Smith <[email protected]> wrote: > > 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 > _______________________________________________ > datatable-help mailing list > [email protected] > https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/datatable-help _______________________________________________ datatable-help mailing list [email protected] https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/datatable-help
