Module 05 of 10

Data Manipulation with dplyr

Lessons

About This Module

Once your data is loaded and clean, the next step is shaping it to answer questions. This module introduces dplyr, the tidyverse package for data manipulation, built around a small set of verbs: filter() to keep rows, select() to choose columns, arrange() to sort, mutate() to create new variables, and summarise() to collapse data into summary values.

You'll also learn the pipe for chaining steps into readable code, and group_by() for computing results within subgroups of your data. Together these let you go from a raw table to a focused summary in just a few lines.

Watch the lessons in order, then continue on to Data Visualization with ggplot2.

Lessons

4 videos
01

Dplyr Essentials (easy data manipulation in R)

A quick tour of the core dplyr functions, covering piping, select, mutate, filter, distinct, group_by, summarise, arrange, and count.

02

Data Wrangling in R with dplyr

Introduces the basic dplyr verbs select(), mutate(), arrange(), and filter(), using a demo R Markdown file you can follow along with.

03

dplyr: Grouping

Explains how group_by() lets summarize() and mutate() work on subgroups of a data frame instead of on entire columns at once.

04

More Data Processing in R with dplyr and tidyr

A follow-along lesson combining filter, mutate, group_by, summarize, and ungroup, plus parse_number from tidyr, on a working dataset.