Inspiration
When I was in graduate school, my Master's Thesis was about building software for Esports researchers to perform experiments and analyze team dynamics and performance in League of Legends.
What it does
This API calculates the ELO rating for teams by using:
- A Proximity Score aggregated from the positional data of each second of the game
- A WinPredictRatio that is calculated using the gold efficiency of a team
How we built it

The main methodology is described in this write-up: https://github.com/devdaniely/lolanalysis-hackathon/blob/master/lol_power_rankings_methodology.pdf
The data was first cleaned and appended to the end-game data provided by OraclesElixer.com. OraclesElixer provided data describing the end state of the game (such as goldEarned, goldSpent, damageDealt, etc.) allowing development to be faster.
Each of the game_files provided (Ex: ESPORTSTMNT03:3199178.json.gz) was then processed to calculate the Proximity Score. This was calculated by getting the positional data for each entry in the game_file, calculating the number of triangles formed by the 5 player positions (10 triangles) that have an area less than the proximity area. Proximity area is a 2000 unit range as defined in a Riot dev post
The WinPredictRatio is calculated based off the Pythagorean Expectation formula that's commonly used in sports analytics. We use gold efficiency as the variable here since it provides a better evaluation of team collaboration throughout an entire game. Gold Efficiency is calculated how much of the earned gold (totalGold - passiveGold) was spent.
Challenges we ran into
- Developing the ELO formula was pretty challenging
- Data needed to be cleaned, joined, and flattened to perform analysis
- We initially explored using AutoGluon to go a machine learning route, but decided to go a route where the rating formula can be explained empirically.
Accomplishments that we're proud of
- Coming up with the proximity score idea
- Calculating the WinPredictRatio using gold efficiency of each team
- Created several scripts to clean and process the data to be interpreted in a meaningful way
What we learned
- Machine Learning is cool, but ultimately hard to explain why a rating was given based on a regression formula created by a neural net.
- Learned more efficient ways of processing data using Pandas
What's next for ELO Rating with Proximity Scores
- Since the game files contain the event data of the entire game, it would be cool to explore how the sequence of events can be analyzed. We could maybe find new strategies by using DNA sequencing algorithms to find interesting event subsequences.
Built With
- amazon-web-services
- api-gateway
- autogluon
- aws-lambda
- jupyternotebook
- python

Log in or sign up for Devpost to join the conversation.