PHPackages                             chasecrawford/ratings - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. chasecrawford/ratings

AbandonedArchivedLibrary

chasecrawford/ratings
=====================

A PHP class which implements the Elo rating system &amp; Rating Percentage index

1.0.0(3y ago)1131PHPPHP &gt;=8.0

Since Jan 11Pushed 3y ago1 watchersCompare

[ Source](https://github.com/chasecrawford/ratings)[ Packagist](https://packagist.org/packages/chasecrawford/ratings)[ Docs](https://github.com/chasecrawford/ratings)[ RSS](/packages/chasecrawford-ratings/feed)WikiDiscussions main Synced today

READMEChangelog (1)DependenciesVersions (3)Used By (0)

Ratings
=======

[](#ratings)

A PHP class which implements the Elo rating system &amp; Rating Percentage index.

Install
-------

[](#install)

```
composer require chasecrawford/ratings
```

Using Elo
---------

[](#using-elo)

Calculate a new elo rating for a competitor after a result

```
use ChaseCrawford\EloRating\Elo;

$newEloRating = Elo::calc(
    1000,   // (float) competitor elo rating
    1000,   // (float) opponent's elo rating
    71,     // (int) competitor score
    70,     // (int) opponent score
    0       // (int) number of matches competitor played previously (optional)
)
```

Find the elo ratings for all competitors from a group of results

```
$results = [...];
$elo = new Elo();

foreach($results as $result) {
  $elo->addResult(
       $result['competitorOneName'],  // (string) unique name for competitor 1
       $result['competitorTwoName'],  // (string) unique name for competitor 2
       $result['competitorOneScore'], // (int) score for competitor 1
       $result['competitorTwoScore']  // (int) score for competitor 2
  )
}

print_r($elo->getCompetitors())
```

Using RPI
---------

[](#using-rpi)

```
use ChaseCrawford\RatingPercentageIndex\RPI;

$results = [...];
$rpi = new RPI();

foreach($results as $result) {
  $rpi->addResult(
       $result['competitorOneName'],  // (string) unique name for competitor 1
       $result['competitorTwoName'],  // (string) unique name for competitor 2
       $result['competitorOneScore'], // (int) score for competitor 1
       $result['competitorTwoScore'], // (int) score for competitor 2
  )
}

print_r($rpi->getCompetitors())
```

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 92.3% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

1214d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8802851b949049e63a4a5f4791f58fe6bf20d9d39480d99c01faea9b06077162?d=identicon)[chasecrawford](/maintainers/chasecrawford)

---

Top Contributors

[![ccrawfordhatfield](https://avatars.githubusercontent.com/u/52418819?v=4)](https://github.com/ccrawfordhatfield "ccrawfordhatfield (12 commits)")[![chasecrawford](https://avatars.githubusercontent.com/u/1011988?v=4)](https://github.com/chasecrawford "chasecrawford (1 commits)")

---

Tags

indexsystempercentageRatingrankingelorpi

### Embed Badge

![Health badge](/badges/chasecrawford-ratings/health.svg)

```
[![Health](https://phpackages.com/badges/chasecrawford-ratings/health.svg)](https://phpackages.com/packages/chasecrawford-ratings)
```

###  Alternatives

[symfony/property-access

Provides functions to read and write from/to an object or array using a simple string notation

2.8k295.3M2.5k](/packages/symfony-property-access)[rennokki/rating

Laravel Eloquent Rating allows you to assign ratings to any model.

19016.9k](/packages/rennokki-rating)[phpskills/phpskills

Implementation of Microsoft's TrueSkill matchmaking system for PHP

773.8k](/packages/phpskills-phpskills)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
