Join Team Batting and Pitching in Python to Build a Run-Differential Table
Join 2024 team batting and pitching on team_id in plain Python, compute run differential and Pythagorean wins for all 30 teams, and find the luckiest club.
Category
Roll up your sleeves. Step-by-step, runnable guides to pulling, charting, and analyzing real baseball data yourself — in Python or a spreadsheet.
Join 2024 team batting and pitching on team_id in plain Python, compute run differential and Pythagorean wins for all 30 teams, and find the luckiest club.
Go from reading FIP to building it: a short, copy-paste Python walkthrough that computes Fielding Independent Pitching from strikeouts, walks, and homers.
Go from reading wOBA to building it. A short, copy-paste Python walkthrough that computes weighted on-base average from raw events using published linear weights.
Turn raw Statcast batted-ball coordinates into a real spray chart. A hands-on Python + matplotlib tutorial you can run on any hitter.
A season-long stat hides hot and cold streaks. Build a rolling expected-wOBA chart in Python to watch a hitter actually heat up and cool off.
Wins lie; run differential doesn't. Build a Pythagorean power ranking of all 30 teams in a spreadsheet, step by step, with real season data.
Statcast, Retrosheet, the MLB Stats API, Lahman and more — every free public baseball data source, ranked by what it's actually good for.
No library, no API key: pull standings, leaders, and live data straight from the public MLB Stats API in Python with nothing but requests.
Pull real MLB data in Python in ten minutes. Install pybaseball, grab a Statcast leaderboard, and make your first chart — with copy-paste-runnable code throughout.