# About KRACH Ratings

Hockey Power Rankings are based upon KRACH, which we believe is the best system to objectively rank teams. KRACH stands for "Ken's Ratings for American College Hockey", named after Ken Butler who first implemented the methodology for college hockey.

KRACH is the implementation of a sophisticated mathematical model known as the Bradley-Terry rating system. While the model is sophisticated, and needs a computer to calculate, its essential meaning is actually quite simple.

The key to understanding KRACH is understanding that it's calculated recursively, so that the end result is self-evident by the results. In other words, if you took one team's schedule to date, and played a theoretical "game" for each game already actually played, using the KRACH ratings themselves in order to predict the winner, then the end result would be a theoretical won-loss percentage that matches the team's actual won-loss percentage. Pretty cool.

## What is it?

KRACH is a team's won/loss ratio multiplied by strength of schedule

- The KRACH rating system is an attempt to combine the performance of each team with the strength of the opposition against which that performance was achieved, and to summarize the result as one number, a “rating”, for each team. The higher the rating, the better the team.
- KRACH accounts for strength-of-schedule (SOS) as it ranks the teams.
- KRACH is calculated purely from the results(win/loss/tie) and does not use goals scored or goal differential like myhockeyrankings.
- Overtime wins count as wins.

## Why do we use KRACH rather than points?

- Teams do not play all the teams in their respective age level
- KRACH does not put greater emphasis on blowing out teams like myhockeyrankings
- Teams that play a more difficult schedule would be punished in the standings based on points

The solver utilizes a Bradley-Terry model to solve for rankings (P) using the paired comparisons. Pairwise means that given a pair of teams i and j drawn from a population P the algorithm estimates the probability that team i will win over team j:

To get to this probability an iterative algorithm with “regularization scheme” and pairwise team win records are used. Per the CHN a logistic regression is used as the solver of the iterative algorithm. The regularization scheme used is an ‘alpha value,’ a regularization scheme so that the solver does not go to infinity when teams have zero wins. The alpha value is 0.85 for every team input as a win against a ‘Dummy Team’. This is because you cannot have zero as the numerator.

The solver then initiates a ranking of 1 for every team, then solves the following equation for each team. The ellipses (…) at the end of the equation represents the sub formula for Team A (Tm A) against Teams C and D.

P Tm A = Total Wins Tm A / ( Sum ( (Losses Tm A vs. Tm B) / (P Tm A + P Tm B), …)

The new P values for each team are calculated using the existing P values as shown above for Team A. These values replace the 1s used to initiate the algorithm. The same calculations are conducted on the new P values for the next iteration of the algorithm. This is repeated 200 times or until the difference of P values between iterations is less than 0.00001. The output (P) is then scaled by 10,000 to make the results all over 1. The iterative nature of the algorithm allows for the strength of schedule to be taken into account automatically without any initial rankings. Thus, no initial rankings are made by hand and no favoritism is possible. Strength of schedule is included in the calculated P value by including the P values of all teams played while calculating each team.

Sources:https://en.wikipedia.org/wiki/Bradley%E2%80%93Terry_model

https://www.collegehockeynews.com/info/?d=krach

https://github.com/bjlkeng/Bradley-Terry-Model/blob/master/update_model.py