[datatable-help] .I does not respect by

Gabor Grothendieck ggrothendieck at gmail.com
Tue Apr 1 13:08:50 CEST 2014


In the following .I seems not to be within group.

> dt <- data.table(a = 1:4, b = 1:2)
> dt[, .I, by = b]
   b .I
1: 1  1
2: 1  3
3: 2  2
4: 2  4
> packageVersion("data.table")
[1] '1.9.3'

This seems contrary to ?data.table.


-- 
Statistics & Software Consulting
GKX Group, GKX Associates Inc.
tel: 1-877-GKX-GROUP
email: ggrothendieck at gmail.com


More information about the datatable-help mailing list