12. Faster Group Manipulation with dplyr
Not to be outdone by Matt Dowle, Hadley Wickham has written a sequel to his famous plyr package that focuses on speed called dplyr. The d
in the name reinforces that the package is meant to work with data.frame
s, while list
and vector
functionality has been moved to the purrr package, which is detailed in Chapter 13. More and more dplyr is becoming the de facto choice for data munging, having nearly replaced plyr. Fortunately for R
users, there is an arms race between Hadley Wickham and Matt Dowle to write the fastest code, and dplyr offers a great mix of speed and ease of use.
Writing code with dplyr involves using the “grammar of data” to perform data munging. Each step is done by a single function that ...
Get R for Everyone: Advanced Analytics and Graphics, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.