I currently use the summaryBy command from the doBy package to group rows of a data frame by specific functions. This works fine. BUT:
The doBy package loads very slow, I think because it imports various other packages. It takes about 3 seconds until doBy is loaded. I only need the simple summaryBy feature from this package.
Is there a possibility to speed up the loading time of the package or is there a alternative implementation which does not load such a huge package?
For aggregating large datasets with complicated functions, it’s hard to beat the data.table package. For example, here’s how you would summarize
meanandsdofSepal.Lengthfor the iris dataset:The library loads quickly, it only takes 1 line of code (2 if you count converting your
data.frameto adata.table), and it’s very fast. What more could you want?