R Foundations: Reproducible Workflow, A Hands-On Course
Code that runs once on your laptop is not enough. Work that a colleague, or you in six months, can rerun and get the same answer is the real goal. This four-lesson interactive course teaches a reproducible R workflow from the ground up, with live code you run as you learn.
You can write correct R and still have it break the moment it leaves your machine: a hard-coded path, a package that changed, a random step with no seed. This course closes those gaps in order: organize a project so paths travel, pin your packages and track changes, learn the modern tools that handle bigger and newer problems, and finally tie it all together in one analysis you could hand to anyone. Every lesson grounds one practice in a single running example.
Each lesson is a guided, interactive experience: you run R right in the page, answer checkpoints, and write code as you go. No setup, no installs.
The four lessons
Lesson 1: RStudio Projects and here
Stop hard-coding paths that only work on your computer. Use an RStudio Project and the here package so every file path resolves from the project root, on any machine.
Start Lesson 1: RStudio Projects and here
Lesson 2: Reproducibility with renv and git
Pin the exact package versions a project uses with renv, and track every change with git, so the project still runs months from now and you can see, and undo, anything you changed.
Start Lesson 2: Reproducibility with renv and git
Lesson 3: The Modern R Toolchain (2026)
The newer tools worth knowing: querying data larger than memory with duckdb and arrow, calling web APIs, and where AI assistance fits into an R workflow without compromising reproducibility.
Start Lesson 3: The Modern R Toolchain (2026)
Lesson 4: Capstone: A Reproducible Analysis
Put it all together: import raw data, tidy it, analyze it and report the result, in one project that anyone can rerun from scratch and reproduce exactly.
Start Lesson 4: Capstone: A Reproducible Analysis
Who this is for
R users who can already import data and write a few functions, and now want their work to be trustworthy and repeatable. This is the capstone of the foundations track. By the end you will set up any analysis so it reproduces cleanly for others and for your future self.
What you will be able to do
- Organize an analysis as a Project with portable, root-relative paths
- Pin package versions with
renvand track history with git - Reach for duckdb, arrow and web tools when base R is not enough
- Run an analysis end to end, from raw data to a reproducible report
- Hand a project to someone else and trust they will get the same answer
This course is part of the free New to R foundations track.