Elo Ratings

A flexible framework for calculating Elo ratings and resulting rankings of any two-team-per-matchup system (chess, sports leagues, 'Go', etc.). This implementation is capable of evaluating a variety of matchups, Elo rating updates, and win probabilities, all based on the basic Elo rating system.


CRAN_Status_Badge Total Downloads Downloads Travis-CI Build Status

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

library(elo)

Please see the vignette for examples. Note that v1.0.0 is very much not backwards-compatible.

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.

News

elo v1.1.0

  • Widened the version dependency to R 3.3.0.

  • Allowed players() matrices in elo.run() to find Elos of individual players playing at the same time.

  • Added elo.glm(), a simple function to run logistic regressions on Elo setups.

  • Fixed a bug in the favored() function (used in summary.elo.run()). (#29)

  • Exported and revamped the class structure of the specials allowed in formulas. (#30)

  • Allowed access to elo.model.frame() even when the package isn't loaded. (#34)

  • Allowed regression to different values for each team. (#35)

elo v1.0.1

Smaller Changes

  • Fixed a bug with initial Elos and deep copying in C++. (#25)

  • Added an argument to regress() allowing users to stop regressing teams which have stopped playing. (#26)

elo v1.0.0

This version is not backwards compatible!

Major Changes:

  • Changed the signatures of elo.calc() and elo.update() to match formula interface.

  • Changed elo.calc(), elo.update(), and elo.prob() to S3 generics, and implemented formula methods. The default methods now include options to adjust Elos. (#3)

  • elo.run():

    • elo.run() no longer accepts numeric values for team.A.

    • elo.run() now accepts special functions group() and regress(). If the latter is used, the class of the returned object becomes "elo.run.regressed". (#11, #12, #19, #22)

    • The $elos component of "elo.run" objects has been completely reworked, and now uses 1-based indexing. Because of this, the print.elo.run() method also had to be fixed. (#16)

  • Renamed last() to final.elos() (#9).

  • Changed tournament dataset.

Smaller Changes:

  • The elo package now imports pROC::auc().

  • elo.prob() now accepts vectors of team names (like elo.run()) as input. (#6)

  • Documentation and the vignette have been updated.

New Functions:

  • Implemented elo.model.frame(). The output is a data.frame with appropriately named columns.

  • Implemented predict.elo.run() and predict.elo.run.regressed(). (#2, #19)

  • Added is.score() to test for "score-ness".

  • Implemented summary.elo.run(), along with helpers to calculate AUC and MSE (auc() and mse()). (#15)

elo 0.1.2

  • Fixed a spelling error in DESCRIPTION.

elo 0.1.1

  • Made the title more succinct.

  • Elaborated the description of the package.

  • Tweak the internal "elo.run" object.

  • Tweaked the README and vignette.

elo 0.1.0

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("elo")

1.1.0 by Ethan Heinzen, 6 months ago


https://github.com/eheinzen/elo, https://cran.r-project.org/package=elo


Report a bug at https://github.com/eheinzen/elo/issues


Browse source code at https://github.com/cran/elo


Authors: Ethan Heinzen [aut, cre]


Documentation:   PDF Manual  


GPL (>= 2) license


Imports Rcpp, pROC

Depends on stats

Suggests knitr, testthat, rmarkdown

Linking to Rcpp


See at CRAN