Learn R Programming

The elo Package

The elo package includes functions to address all kinds of Elo calculations.

  • elo.prob(): calculate probabilities based on Elo scores

  • elo.update(): calculate Elo updates

  • elo.calc(): calculate post-update Elo values

  • elo.run() and elo.run.multiteam(): calculate "running" Elo values for a series of matches

It also includes comparable models for accuracy (auc, MSE) benchmarking:

  • elo.glm() which fits a logistic regression model

  • elo.markovchain() which fits a Markov chain model

  • elo.colley() for a method based on the Colley matrix.

  • elo.winpct() which fits a model based on win percentage

Please see the vignettes for examples.

Naming Schema

Most functions begin with the prefix "elo.", for easy autocompletion.

  • Vectors or scalars of Elo scores are denoted "elo.A" or "elo.B".

  • Vectors or scalars of wins by team A are denoted by "wins.A".

  • Vectors or scalars of win probabilities are denoted by "p.A".

  • Vectors of team names are denoted "team.A" or "team.B".

Copy Link

Version

Install

install.packages('elo')

Monthly Downloads

593

Version

3.0.2

License

GPL (>= 2)

Issues

Pull Requests

Stars

Forks

Maintainer

Last Published

August 23rd, 2023

Functions in elo (3.0.2)

summary.elo

Summarize an elo Object
players

Details on elo formulas and the specials therein
elo

The Elo Package
fitted.elo

Extract model values
elo.model.frame

Interpret formulas in elo functions
elo.mov

Create a "margin of victory" column
elo.run.multiteam

Calculate running Elos for a series of multi-team matches.
elo.update

Elo updates
elo.calc

Post-update Elo values
elo.colley

Compute a Colley matrix model for a matchup.
elo.glm

Compute a (usually logistic) regression model for a series of matches.
elo.mse

Calculate the mean square error
auc.elo

Calculate AUC on an elo.run object
tournament

tournament: Mock data for examples
elo.markovchain

Compute a Markov chain model for a series of matches.
elo.run

Calculate running Elos for a series of matches.
elo.prob

Elo probability
elo.run.helpers

Helper functions for elo.run
tournament.multiteam

tournament.multiteam: Mock data for examples
score

Create a 1/0/0.5 win "indicator"
predict.elo

Make Predictions on an elo Object
rank.teams

Rank teams
favored.elo

Classify teams that are favored to win
elo.winpct

Compute a (usually logistic) regression based on win percentage for a series of matches.