Pipelines were the best thing to happen in R in 2014. They let us transform messy, inside-out code like
sort(unique(round(xs, 2)))
into a clear chain of transformations likexs %>% round(2) %>% unique %>% sort
. In this talk I lead a tutorial on how to use pipelines for data-cleaning, transformation and presentation with the packagesmagrittr
anddplyr
. For beginners, I also review some of the essential R functions to make the most of pipelines.Tristan is a PhD student in Communication Sciences and Disorders. He uses in R in the Learning To Talk lab to model eye-tracking and speech perception data. @tjmahr, github.com/tjmahr.
I prepared three sets of slides:
- magrittr vignette
- RStudio Data-Wrangling Cheatsheet
- Core R vocabulary
- Awesome R
- Pipelines for Data Analysis (dpylr/magrittr talk by Hadley Wickham)
- Best Practices for Scientific Computing
- Data Science on the Command Line
- Unix Commands for Data Science
- magrittr for pipelines
- dplyr for data-frame functions
- broom
- stringr for string manipulation functions
- pipeR an alternative pipeline package (that I haven't tried yet).
Obviously, the GPL-2 license applies only to the code and words I wrote, which
are in the .Rpres
and .md
files and are reproduced with markup in the
.html
files.