WarrierRajeev / UFC-Predictions

A web app to predict UFC fights
https://ufc-predictions.rajeevwarrier.com
114 stars 50 forks source link
machine-learning ufc

UFC predictions

Usage

UFC app

Details

Results

Confusion Matrix

Details about the data

Context

This is a list of every UFC fight in the history of the organisation. Every row contains information about both fighters, fight details and the winner. The data was scraped from ufcstats website. After fightmetric ceased to exist, this came into picture. I saw that there was a lot of information on the website about every fight and every event and there were no existing ways of capturing all this. I used beautifulsoup to scrape the data and pandas to process it. It was a long and arduous process, please forgive any mistakes. I have provided the raw files incase anybody wants to process it differently. This is my first time creating a dataset, any suggestions and corrections are welcome!

How to use from Scratch?

(Note: This will scrape everything from the beginning if you haven't used this before. Otherwise the command will update the data files. Then, it will preprocess the raw scraped files to create usable data files)

Content

Each row is a compilation of both fighter stats. Fighters are represented by 'red' and 'blue' (for red and blue corner). So for instance, red fighter has the complied average stats of all the fights except the current one. The stats include damage done by the red fighter on the opponent and the damage done by the opponent on the fighter (represented by 'opp' in the columns) in all the fights this particular red fighter has had, except this one as it has not occured yet (in the data). Same information exists for blue fighter. The target variable is 'Winner' which is the only column that tells you what happened. Here are some column definitions:

Column definitions:

Acknowledgements