How leoegidi/footbayes works
footBayes is an R package for fitting football score and team-strength models, then examining model results and predictions. The documented example runs from match data through a Bayesian fit to ability plots, posterior predictive checks, league rankings, and outcome probabilities. The README also describes MLE, model comparison, and Bradley–Terry–Davidson strengths as a covariate. Source excerpts were not provided, so relationships below are limited to documented capabilities and workflow; individual Stan model variants are represented together.
Main entry points: stan_foot.R Bayesian fit · btd_foot.R Bradley–Terry–Davidson · italy.rda Italy dataset · england.rda England dataset
Components 16
Model fitting
- Bayesian fit
R/stan_foot.R - MLE fit
R/mle_foot.R - Stan models
src/stan
Team strengths
- Bradley–Terry–Davidson
R/btd_foot.R
Results and diagnostics
- Team abilities
R/foot_abilities.R - Posterior checks
R/pp_foot.R - Ability plots
R/plot_logStrength.R - BTD posterior plot
R/plot_btdPosterior.R
Prediction
- League ranking
R/foot_rank.R - Outcome probabilities
R/foot_prob.R - Model comparison
R/compare_foot.R - Round-robin outcomes
R/foot_round_robin.R
Other components
- Analyst
- Match data
- Italy dataset
data/italy.rda - England dataset
data/england.rda
Connections 16
- Analyst → Bayesian fit: fits model
README.md - Match data → Bayesian fit: provides matches
README.md - Bayesian fit → Stan models: fits with
README.md - Analyst → MLE fit: fits by MLE
README.md - Analyst → Bradley–Terry–Davidson: estimates strengths
README.md - Bradley–Terry–Davidson → Bayesian fit: supplies covariate
README.md - Bayesian fit → Team abilities: examines effects
README.md - Bayesian fit → Posterior checks: checks fit
README.md - Bayesian fit → Ability plots: visualizes strengths
README.md - Bradley–Terry–Davidson → BTD posterior plot: visualizes posterior
- Bayesian fit → League ranking: reconstructs league
README.md - Bayesian fit → Outcome probabilities: predicts outcomes
README.md - Analyst → Model comparison: compares models
README.md - Analyst → Round-robin outcomes: analyzes outcomes
- Italy dataset → Bayesian fit: example input
README.md - England dataset → Bayesian fit