Home » Data Manipulation in R with dplyr, tidyr, stringr, and lubridate

Data Manipulation in R with dplyr, tidyr, stringr, and lubridate

Duration: 5 weeks

Target Audience: R users with basic knowledge and data handling experience aiming to master data manipulation techniques.

Week 1: Introduction to Data Manipulation in R

  • Overview of dplyr, tidyr, stringr, and lubridate packages.
  • Importance of data wrangling in analysis workflows.
  • Assignment: Load a dataset and perform basic dplyr operations (filter, select).

Week 2: Data Transformation with dplyr and tidyr

  • Key dplyr functions: mutate, group_by, summarise, arrange.
  • Reshaping data with tidyr: pivot_longer, pivot_wider.
  • Assignment: Transform and reshape a dataset using dplyr and tidyr.

Week 3: String Manipulation with stringr

  • Regular expressions, string detection, replacement, splitting.
  • Cleaning text data in real-world scenarios.
  • Assignment: Clean a dataset with inconsistent text entries using stringr.

Week 4: Date and Time Handling with lubridate

  • Parsing dates, extracting components, date arithmetic.
  • Managing time series data effectively.
  • Assignment: Manipulate a dataset with date-time variables (e.g., sales data).

Week 5: Capstone Project

  • Combine dplyr, tidyr, stringr, and lubridate to clean and transform a complex dataset.
  • Present a cleaned dataset with a summary report.
  • Final review and feedback.