Agentic data-vis workshops

Occasional, hands-on workshops on data visualisation with an agentic AI assistant, grounded in Wilkinson’s grammar of graphics. The work is mainly in R with ggplot2, with excursions into Vega-Lite and plotnine to show the grammar moving between languages. Each session takes one TidyTuesday (or equivalent) dataset and builds a visualisation live. Every design decision is made by the people in the room. The agent fetches and describes the data, writes the code, renders the result, and reports what it sees.

There’s no fixed schedule. Sessions happen when someone offers to run one, and the repo is public so that anyone can: clone it, open it in an IDE with Claude Code, Codex, or another coding agent, and the same skills and instructions apply. Started by Jon Minton.

How the sessions work

Plots are specified before they are coded. The group dictates mapping rules: which variable goes to which aesthetic, which geoms, which scales. These are recorded in a short YAML spec that the group argues over on the shared screen, then compiled to code and rendered. The spec trail is the record of the design decisions. See a worked example of the round trip.

For anyone who would rather point and click than write YAML, the mapping builder lets you draw the same mapping rules as arrows from variables to aesthetics. It shows the figure, the spec and the ggplot2 code updating together.

The opposite of “the analyst decides” is an agent that decides everything: the dataset, the question and every figure. That is the claude-fable-vision-ds-test experiment (repository), which these workshops use as a point of contrast. Its probability-phrases page covers one of the datasets offered in Session 1.

The repo gives the agent three skills, each a plain-markdown procedure that any agent can follow:

  • tt-fetch fetches a TidyTuesday week and describes it in grammar terms. It proposes mappings and never chooses one.
  • gg-spec compiles a YAML spec to ggplot2, renders it, and looks at the result. It walks the grammar one slot at a time, so the room makes each decision.
  • dataset-scout finds datasets that stress a particular grammar layer, for planning a session.

After a session, a page may be drafted from the spec trail and notes, recording the design decisions as decisions, the pain points, and the lessons learned. The session’s facilitator reviews and approves it before it is published.

Sessions

  • 2026-09-29, a demonstration at a university data-vis lab. Slides. The room chose The Office: IMDb ratings for every episode, built into a season-by-episode heatmap and then ratings over air date. The session workbook, and version 2, which continues it after the session. Version 2 adds revised specs, a 3D view with explicit linear models, and an autonomously produced section on the transcripts.
  • 2026-10-16, music sales and styles. No TidyTuesday week has real sales data, so the room chose Rolling Stone’s “500 Greatest Albums” lists from 2003, 2012 and 2020. The session workbook runs from the shortlist through the data description to two figures: release year against rank, and a Sankey-style chart of how the genre of the top five changed.

Candidate datasets

Preparation notes describe a dataset before any session uses it. They offer options and make no design decisions; the group makes those on the day.

  • 2026-10-09. Global fertility: the gapminder country indicators, a candidate for a geoms-and-stats session, with two Rosling-style reference figures to react to. A&E waits and delayed discharges: two Public Health Scotland datasets that are usually analysed separately, put on one plot. It’s a candidate for a session on layers that each have their own data.
  • 2026-10-13. Front door, ward, back door: the same NHS data with a third silo, acute bed occupancy. The plotting code names each part of the patient’s journey, so that cross-silo charts become the natural thing to write.