Arpad: ELO Rating System for Node.js
This is an implementation of ELO for Node.js (ELO is named after Arpad Elo, hence the package name). This module is heavily tested and has many features used in real-world ELO situations.
Installation
npm install arpad
Simple Usage
This is a fairly simple example showing the most common usage for Arpad:
const Elo = ; const elo = ; let alice = 1600;let bob = 1300; let new_alice = elo;console; // 1605 let new_bob = elo;console; // 1327
Complex Usage
This is a more complex example, making use of K-factor tables and score values:
const Elo = ; const uscf = default: 32 2100: 24 2400: 16; const min_score = 100;const max_score = 10000; const elo = uscf min_score max_score; let alice = 2090;let bob = 2700; let odds_alice_wins = elo;console; // ~2.9%alice = elo;console; // 2121 odds_alice_wins = elo;console; // ~3.4%alice = elo;console; // 2144
Running Tests
If you'd like to contribute be sure to run npm install
to get the required packages and then make changes.
Afterwards simply run the tests.
If everything passes your Pull Request should be ready.
npm test
License
MIT