SPMC 350 · University of Nebraska-Lincoln

Learn Sports Data Analysis with R. Free. Open source. Self-paced.

40 interactive tutorials that teach R programming through real sports data — the same materials used in SPMC 350 at UNL's College of Journalism and Mass Communications. No enrollment required.

How it works

download

1. Install R & RStudio

Both are free and open-source. R is the statistical computing language; RStudio is the editor that makes working with R comfortable.

package_2

2. Install the package

One command installs all 40 tutorials directly from GitHub. They run inside RStudio's built-in Tutorial tab — no browser, no accounts.

school

3. Work at your own pace

Each tutorial is interactive — write and run code directly in the lesson. Make mistakes, experiment, and reread as many times as you need.

RStudio Console

# Step 1: install required packages

install.packages("devtools")

# Step 2: install the tutorials

devtools::install_github("mattwaite/SportsDataTutorials")

What you'll learn

01

Lessons 1–12

R Fundamentals & Statistics

Start from zero. Learn to use R as a calculator, load and clean data, filter and summarize sports statistics, and understand the math behind what you read — significance tests, regressions, z-scores, and residuals.

tidyverse dplyr t-tests regression z-scores
02

Lessons 13–27

Data Visualization with ggplot2

Build 15 different chart types using ggplot2 — from simple bar charts to bump charts and dumbbell charts. Learn when to use each one and how to make publication-quality graphics that tell a clear story.

ggplot2 bar charts scatterplots bump charts faceting
03

Lessons 28–37

Advanced Topics

Go further: publish data stories as a blog with Quarto and GitHub Pages, scrape sports tables from websites with rvest, clean messy text data, use color and annotations effectively, and apply clustering and simulation methods.

Quarto rvest clustering simulation joins
04

Lessons 38–40

Reference Guides

Practical reference material: how to pull data from Sports Reference into R, a project checklist for data-driven stories, and a full index of every function and concept covered across all 40 tutorials.

Sports Reference project checklist function index

What students say

"The tutorials are genius... Going through at my own pace, being able to try practice problems that have no real effect if I get them wrong, and getting to reread things as many times as I needed to, made me get comfortable and confident with what we were doing super fast."

Spring 2025 · SPMC 350

"The RStudio tutorials were extremely beneficial to my learning and success in this class. It was easy to learn step by step how to do things, and bring that over to do by ourselves."

Spring 2022 · SPMC 350

"The tutorials are really easy to follow and help me understand the goal of the assignments and how to complete them. They were also beneficial during projects because it allowed me to look back at previous work as a reference."

Spring 2023 · SPMC 350

Open source & free forever

These tutorials were developed for SPMC 350 at the University of Nebraska-Lincoln's College of Journalism and Mass Communications, but they belong to everyone. The package is MIT-licensed and the source is on GitHub.

If you're a student, a journalist learning data skills on your own, or an instructor who wants to use these materials in your own course — go ahead. No registration, no fee, no waitlist.

check_circle

40 interactive tutorials

Write and run real R code inside each lesson

check_circle

Real sports data throughout

Nebraska baseball, college football, NBA, and more

check_circle

No prerequisites

Designed for journalists with zero coding experience

check_circle

MIT license

Use it, modify it, teach with it — it's yours