Giter Club home page Giter Club logo

pl-predictions-using-fifa's Introduction

Premier League predictions using fifa ratings

Python 3.6 License: MPL 2.0 Twitter Follow

This is the code base I created to both collect football data, and then use this data to train a neural network to predict the outcomes of football matches based on the fifa ratings of a team's starting 11.

See the blog post for more information on the methodology.

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

You'll need:

To install the dependencies,

pip install -r requirements.txt`

Crawlers

The crawlers are all written using Scrapy. For proper usage it would be beneficial to first know how to use Scrapy.

For a quick start, just go to ./fifa_ratings_predictor/crawler and use

scrapy crawl <spider name> -o <output file>

It goes without saying that if you do use these crawlers, please don't bombard the sites with a stupid amount of requests - scrape responsibly.

I have deliberately left all of the data off of the repo because a) it's not really my data and b) it's not good practice to have data on a repo.

Installing

To install everything except the crawler you can run

pip install .

from the top level directory.

You can then import the methods, for example the simulator,

from fifa_ratings_predictor.simulation import SeasonSimulator

Built With

Issues

Get in contact on Twitter if you have any issues.

Authors

Bradley Grantham

License

This project is licensed under the MPL-2.0 License - see the LICENSE file for details

pl-predictions-using-fifa's People

Contributors

bradleygrantham avatar travelhawk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pl-predictions-using-fifa's Issues

Results from log post not repeatable

I tried to repeat the results from your blog posts, but I didn't get a positive bankroll. It is also a bit confusing since there a different scripts not working together. The script bot.py uses BeautifulSoap and webdriver while the other scripts use the data collected from scrapy. However bot.py doesn't work on my computer too.

read_all_football_data

Hello Bradley,

This repo is very interesting and inspiring!
May I know how do you get / generate the csv files required in the captioned function?
Thanks.

Regards,
Herman

fifastats spider not working properly

Dear Bradley,
I have an issue that the fifastats spider is not working properly. I checked and the problem is in the parse_player method, where I get IndexError index out of range when gathering name parameter. I checked the script and until that point it works properly it seems that the response html structure have changed or something like that happened since the name is empty. Could you validate that this is the problem, please?
Impressed by your work,
Greg

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.