skillratings
Calculate a player's skill rating in 1v1 matches instantly using Elo, TrueSkill, DWZ, Glicko and Glicko-2 algorithms known from their usage in chess and online games.
Skillratings is only for calculating 1v1 matches, teams are not supported. Also we calculate the results instantly, instead of at the end of every rating period.
Installation
Add the following to your Cargo.toml file:
[]
= "0.6.0"
Usage
For a detailed guide on how to use this crate, head over to the documentation.
Elo rating system
extern crate skillratings;
use ;
let player_one = EloRating ;
let player_two = EloRating ;
// The outcome is from the perspective of player one.
let outcome = WIN;
let = elo;
assert!;
assert!;
Glicko rating system
use ;
let player_one = GlickoRating ;
let player_two = GlickoRating ;
let outcome = WIN;
let = glicko;
assert!;
assert!;
assert!;
assert!;
Glicko-2 rating system
extern crate skillratings;
use ;
let player_one = Glicko2Rating ;
let player_two = Glicko2Rating ;
let outcome = WIN;
let = glicko2;
assert!;
assert!;
assert!;
assert!;
TrueSkill rating system
Caution regarding usage of TrueSkill: Microsoft permits only Xbox Live games or non-commercial projects to use TrueSkill(TM). If your project is commercial, you should use another rating system included here.
todo!
DWZ rating system
The statements above hold true here as well.
use ;
let player_one = DWZRating ;
let player_two = DWZRating ;
let outcome = WIN;
let = dwz;
assert!;
assert_eq!;
assert!;
assert_eq!;
License
This project is licensed under the MIT License.