Dugout Value
Baseball research on pitching, hitting, and projections, plus tools for comparing players, contracts, and trade value.
See sport differently: independent analytics, player ratings, match predictions and simulations for football, AFL, tennis and athletics.
Sports & fitnessR · HTMLGitHub @peteowen1OnlineOwner unconfirmed
Have you tried it? One tap is enough. No sign-in needed.
No updates detected yet. GitHub releases will appear here.
Owners of public repositories under a personal GitHub account can sign in to verify ownership and manage the introduction themselves. No administrator approval is needed.
Sign in, generate a verification file, and commit it to this repository’s default branch within 30 minutes. Files on other branches or forks do not count. Then check the file below to manage the project without administrator approval. Keep the file to retain your access.
If needed, you will go to sign-in. After signing in, return here and press your chosen verification button again.
Run /nomorevibe verify in your project folder to verify ownership and manage the introduction yourself.
Verify in one minuteAsk about other verification options
AFL play-by-play data and player contribution scores
Translation pending
Taken from the repository README
Loading the full README. The saved excerpt is shown below.
TORP ratings, match predictions and season simulations built with this package are published, updated after every round, at inthegame.blog/afl.
torp is an R package for AFL analytics. It provides player ratings
(TORP), expected points and win probability models, season simulations,
and easy access to processed AFL data.
All data is stored as parquet files on
torpdata GitHub releases and
loaded on demand.Read the full README ↗TORP ratings, match predictions and season simulations built with this package are published, updated after every round, at inthegame.blog/afl.
torp is an R package for AFL analytics. It provides player ratings (TORP), expected points and win probability models, season simulations, and easy access to processed AFL data.
# install.packages("devtools")
devtools::install_github("peteowen1/torp")
# For the latest pre-trained models
devtools::install_github("peteowen1/torpmodels")
All data is stored as parquet files on torpdata GitHub releases and loaded on demand.
library(torp)
# Play-by-play data
pbp <- load_pbp(2025, rounds = 1:10)
# Player statistics
player_stats <- load_player_stats(2025)
# Match results and fixtures
results <- load_results(2025)
fixtures <- load_fixtures(all = TRUE)
# All available data (2021+)
pbp_all <- load_pbp(TRUE, rounds = TRUE)
TORP blends two independent rating systems: EPR (from play-by-play data) and PSR (from box-score stats via Bayesian estimation + glmnet). Per-game equivalents EPV and PSV measure single-game contribution.
# Career TORP ratings (EPR + PSR blend)
ratings <- torp_ratings()
# Per-game values (EPV + PSV + torp_value)
game_ratings <- player_game_ratings(season_val = 2026)
# Season totals
season_totals <- player_season_ratings(2026)
# Bayesian stat ratings (per-stat next-game predictions)
stat_ratings <- load_player_stat_ratings(2026)
Three core models add expected points, win probability, and shot outcome predictions to play-by-play data.
pbp <- load_pbp(2025, rounds = 1:5)
pbp_clean <- clean_pbp(pbp)
# Add model predictions
pbp_ep <- add_epv_vars(pbp_clean) # Expected points
pbp_wp <- add_wp_vars(pbp_ep) # Win probability
# Simulate remaining matches based on TORP ratings
sim_result <- simulate_season(sim_teams, sim_games)
| Package | Role | Links |
|---|---|---|
| torp | Core analytics, data loading, ratings, models | GitHub |
| torpdata | Processed AFL data via GitHub releases (parquet) | GitHub |
| torpmodels | Pre-trained models via GitHub releases (RDS) | GitHub |
Data flows from the AFL API (via torp’s get_afl_*() functions) through
torp’s cleaning pipeline into torpdata, with models stored in
torpmodels.
vignette("getting-started") – Installation and data loadingvignette("torp-guide") – Ratings, models, data architecture, and
simulationMIT