2017 © Pedro Peláez
 

library elo-rating

A PHP class which implements the Elo rating system.

image

chovanec/elo-rating

A PHP class which implements the Elo rating system.

  • Sunday, July 6, 2014
  • by Chovanec
  • Repository
  • 0 Watchers
  • 0 Stars
  • 112 Installations
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 1 % Grown

The README.md

Elo Rating PHP

A PHP class which implements the Elo rating system., (*1)

Install with composer

composer require chovanec/elo-rating dev-master, (*2)

Link to Packagist.org: https://packagist.org/packages/chovanec/elo-rating, (*3)

Usage

require 'src/Rating/Rating.php';

// player A elo = 1000
// player B elo = 2000
// player A lost
// player B win

$rating = new Rating(1000, 2000, Rating::LOST, Rating::WIN);

// player A elo = 1000
// player B elo = 2000
// player A draw
// player B draw

$rating = new Rating(1000, 2000, Rating::DRAW, Rating::DRAW);

$results = $rating->getNewRatings();

echo "New rating for player A: " . $results['a'];
echo "New rating for player B: " . $results['b'];

Credits

Creative Commons License
Elo Rating PHP by Michal Chovanec is licensed under a Creative Commons Attribution 4.0 International License., (*4)

The Versions

06/07 2014

dev-master

9999999-dev

A PHP class which implements the Elo rating system.

  Sources   Download

CC BY 4.0

php rating elo