I see now, thanks for explaining that. Would it be for you to add data.table methods to ddply then, for this to happen? Or does a ddply method need to be added to data.table?
"hadley wickham" <h.wick...@gmail.com> wrote in message news:f8e6ff051001200825q4009a122m122082a9df5fe...@mail.gmail.com... > On Wed, Jan 20, 2010 at 8:43 AM, Matthew Dowle <mdo...@mdowle.plus.com> > wrote: >> Sounds like a good idea. Would it be possible to give an example of how >> to >> combine plyr with data.table, and why that is better than a data.table >> only >> solution ? > > Well, ideally, you'd do: > > adt <- data.table(a) > ans2 <- ddply(a, c("var1", "var2", "var3"), subset, dt - min(dt) < 7) > > and ddply would take care of the details. > > Why would it be better? Because plyr works for all data types: data > frames, lists and arrays. > > Hadley > > -- > http://had.co.nz/ > ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.