I have a very strange row-filtering issue in front of me that I can only 
reproduce on a very large data set.  Let me start off by giving you the end 
symptoms and then I will talk through some  hacks which will avoid the bug.

I have two fields of interest -- pred_bad_t_f and weight.- pred_bad_t_f is of 
class "integer" with two unique values, 0 and 1- weight is of class "numeric"
> dt[pred_bad_t_f == 1, sum(weight)]
[1] 6580818130
> dt[pred_bad_t_f == 1L, sum(weight)]
[1] 5414941720
As you can see, there is no reason for the second value to be any different.  I 
believe the first value is correct because slight changes to the filtering 
logic generates that value repeatedly.  Below are some examples:

> dt[1:nrow( dt)][pred_bad_t_f == 1L, sum(weight)]
[1] 6580818130> dt[TRUE & pred_bad_t_f == 1L, sum(weight)]
[1] 6580818130
s
_______________________________________________
datatable-help mailing list
[email protected]
https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/datatable-help

Reply via email to