Chapter 7 Notes — Visualizing Cricket

Chapter link: Chapter 7

Overview and learning objectives

Chapter 7 teaches cricket's chart repertoire and when each chart lies. The hook is Kavya Subramanian's "thumb test" on Anchor A (Newlands, 25 January 2017): the worm says Sri Lanka (116/2 after 15 overs) are level with South Africa (119/3 at the same point); the run-rate chart says they score at 7.73 and need 10.80; and the Manhattan shows Imran Tahir's over 16 (two runs, two wickets) followed by the tallest bar of the night. Three charts, three stories, one match. The chapter covers Manhattans, worms and run-rate charts, partnership bars, heat maps (sequential and diverging), small multiples, control charts, radars (and their problems), wagon wheels, pitch maps and beehives from the simulated tracking layer, and design for colour-vision deficiency and the phone screen. The Crease module is charts.py (23 functions), which every later chapter imports.

By the end of the chapter students should be able to:

  1. Choose a chart from the question it must answer (the 7.1 table), not from habit.
  2. Draw and read a Manhattan, worm, run-rate chart and partnership bars for any match, and state what each cannot show.
  3. Build a heat map with printed values, suppressed small cells and a diverging scale centred on the league rate.
  4. Use an XmR control chart to tell a real shift (IPL first-innings totals from 2023) from ordinary noise, and distinguish a signal from a cause.
  5. Critique a radar chart (axis order changes area; percentiles depend on the pool) and offer an honest alternative.
  6. Label every simulated-tracking chart correctly and refuse to state a simulated value as a fact about a real player.
  7. Apply the book's visual conventions (batting first blue, second orange, wickets red X; Okabe–Ito for comparisons) and the seven-step pre-publication checklist.

Where students struggle

  • The worm read as win probability. "The lines crossed, so the chasing side was winning." The worm ignores wickets and assumes the first innings is par.
  • Manhattan bars read as batting. A bar is runs conceded in the over, including extras; it says nothing about who scored or the match state (Exercise A.4).
  • Vivid colour on tiny samples. Klaasen's powerplay cell (−35.8 on 52 balls) looks as solid as a 635-ball cell. The book suppresses cells under 30 balls.
  • Signal versus cause. The control chart flags 2023–2026 as outside the limits; it does not prove the Impact Player rule caused it.
  • Simulated tracking. Students instinctively read simulated wagon wheels and beehives as real. The check-your-understanding example — yorkers 27.5% of Bumrah's simulated death dots v 5.6% of his boundaries — is a property of the simulation's rules, not a finding.
  • Colour. Red/green is the default in many tools. Under simulated deuteranopia the tab10 red–green difference falls from 119.8 to 7.3 (CIE76); blue–orange keeps 118.1 of 122.0.
  • Truncated bar axes. A y-axis starting at 7.5 turns a 45% difference into an apparent 330% difference (Exercise B.9).
  • Windows consoles. Run scripts with PYTHONIOENCODING=utf-8 if em dashes in printed titles cause encoding errors.

Pacing

50-minute session. - 0–8: The thumb test on the worm and run-rate chart. - 8–18: Manhattan and worm (7.2–7.3), with the pitfalls. - 18–25: Partnership bars and the Productive Struggle (which stand cost Sri Lanka most?). - 25–35: Heat maps and small multiples (7.5–7.6). - 35–43: Control chart (7.7). - 43–50: Simulated tracking (7.9) — what can and can't be said.

75-minute session. Add radars (7.8, 10 minutes) and design for the reader (7.10, 15 minutes, including the before/after redesign of the IPL 2026 team phase chart). Lab time: 60–90 minutes; students should produce at least one dashboard and one redesign.

Lecture outline

  1. Two charts, one chase: worm v run-rate chart at Newlands after 15 overs.
  2. What a chart is for; the book's conventions (colours, orientations, simulated-data labels, sample suppression).
  3. Manhattan: over table → bars; reading it; format differences (grouped overs for ODIs; wrong chart for Tests).
  4. Worm and run-rate chart: SL after 10 overs 81/2 v SA 79/1; RRR 8.90 after 10, 10.80 after 15, 13.00 after 16; interactive worms.
  5. Partnership bars: de Silva–Dickwella 71 off 61 (6.98 an over against a need of about 9).
  6. Heat maps: IPL run rate by over × year (lowest 2013 over 1 = 5.16; highest 2019 over 20 = 13.05; over 7 below over 6 in every season); diverging phase SR v league (2024–26: powerplay 153.12, middle 144.50, death 171.61).
  7. Small multiples: 2026 knockouts on shared axes.
  8. Control charts: 2008–22 baseline mean 163.1, average moving range 5.96, limits 147.3–179.0; 2023–26 all above.
  9. Radars: women's T20I openers (Mandhana, Mooney, Wolvaardt, Athapaththu); Deepti Sharma's radar area varies 35% with axis order; strip plots as the honest alternative.
  10. Wagon wheels, pitch maps, beehives — simulated and labelled; what a franchise with Hawk-Eye would see differently; Wendell's "where were the batter's feet?"
  11. Design: before/after; colour-vision measurement; annotation; the phone screen.

Live coding demo

Script: code/01_anchor_manhattan_worm.py (its printed output is also saved in code/01_output.txt).

  1. Run it and open the Manhattan, worm and run-rate figures. Expected printed values: phase totals SA 48/1, 71/2, 50/2; SL 48/2, 68/0, 54/3; after 15 overs SL 116/2 v SA 119/3; RRR 10.80 after 15 and 13.00 after 16; SA's over 20 went for 21.
  2. Apply the thumb test live: cover each title and ask a student what the chart says.
  3. Live change 1: in the worm call, set label_wickets=True and add an annotation for Tahir's over, e.g. annotate=[(2, 16, "Tahir: 2 runs, 2 wkts")]. Show how a single annotation changes the reading.
  4. Live change 2: change the Manhattan's colours to red and green, then show the colour-vision figure from 07_design_principles.py — the red–green distinction collapses to 7.3 under deuteranopia.
  5. Optional: 04_small_multiples_control.py — show the control chart; move the baseline end year from 2022 to 2023 and ask what happens to the limits (do not pre-state numbers).

In-class activity — "Fix the chart"

Show the chapter's "before" chart of IPL 2026 team run rates by phase (rainbow colours, alphabetical order, truncated axis). Groups list everything wrong in five minutes, then sketch an "after" on paper using the 7.10 principles. Give them the real values for two teams (Delhi Capitals 8.67 / 9.17 / 11.41; Punjab Kings 10.95 / 9.97 / 12.55) and have them settle the fan's claim that Delhi were "the best death-overs side" (they weren't: Punjab 12.55 and RCB 11.57 were higher; Delhi's distinction was the widest gap between a slow powerplay and a fast death).

Answers and teaching notes for key exercises

  • B.1 After 15: CRR 7.73, RRR 10.80. After 16: CRR 7.38, RRR 13.00 — up 2.20 and two wickets lost.
  • B.2 SA 8.00 / 7.89 / 10.00; SL 8.00 / 7.56 / 11.17 (54 off 29 legal balls). Level in the powerplay, SA faster in the middle, SL faster at the death.
  • B.3 6.98 an over; Dickwella 74% of bat runs; at 9 an over the 61 balls "should" have yielded 91.5 — about 20 short. Use with the Productive Struggle: a partnership chart doesn't know the target.
  • B.4 163.1 ± 2.66 × 5.96 = 147.3 to 179.0; 2026's 195.7 sits 5.47 moving ranges above the centre.
  • B.6 Red–green keeps about 6% of its difference under deuteranopia; blue–orange about 97%. Shapes (the X marker) must carry wicket information.
  • B.9 On an axis starting at 7.5, Punjab's death bar looks about 4.3× Delhi's powerplay bar; the real ratio is 1.45.

Assessment ideas

  • Match report (graded): a one-page visual report on any match using charts.match_dashboard, with a title that states the message and a 150-word caption. Assess with the seven-step checklist.
  • Critique task: students find a published cricket chart (broadcast or web), apply the thumb test and the checklist, and propose one fix.
  • Short answer: "Why is the yorker share of Bumrah's simulated dot balls not a finding?"
  • Code task: Exercise C.4 — a control chart of men's T20I first-innings totals between full members, with a sentence that separates signal from cause.

Format, gender and region diversity notes

  • Case Study 1 is the 2026 Women's T20 World Cup final (Australia 153/3 beat England 150/4; Mooney 64 off 49, player of the match); Case Study 2 is Headingley 2019, a Test chart that needs wickets and time, not run rate.
  • The radar section uses women's T20I openers from a pool of 103 batters; remind students that Chamari Athapaththu appears as "AC Jayangani" in the data.
  • The 2026 knockout small multiples mix men's T20 World Cup, IPL playoffs and the women's World Cup on shared axes — a good prompt to talk about which comparisons are fair across competitions.
  • Exercise D.1 asks whether the run-rate chart works for ODIs, Tests and The Hundred: use it to reinforce Chapter 5's format-awareness.
  • Accessibility is a diversity issue too: colour-blind-safe palettes and described figures (every figure in the book has a "Figure (described)" note) make charts usable for more readers.

Connections