penaltyblog


Namepenaltyblog JSON
Version 0.8.0 PyPI version JSON
download
home_pagehttps://github.com/martineastwood/penaltyblog
SummaryLibrary from http://pena.lt/y/blog for scraping and modelling football (soccer) data
upload_time2023-08-31 18:54:22
maintainer
docs_urlNone
authorMartin Eastwood
requires_python>=3.8,<3.12
licenseMIT
keywords football soccer goals modelling dixon coles poisson bayesian scraper scraping backtest
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Penalty Blog

<div align="center">

  <a href="">[![Python Version](https://img.shields.io/pypi/pyversions/penaltyblog)](https://pypi.org/project/penaltyblog/)</a>
  <a href="">[![Coverage Status](https://coveralls.io/repos/github/martineastwood/penaltyblog/badge.svg?branch=master&service=github)](https://coveralls.io/repos/github/martineastwood/penaltyblog/badge.svg?branch=master&service=github)</a>
  <a href="">[![PyPI](https://img.shields.io/pypi/v/penaltyblog.svg)](https://pypi.org/project/penaltyblog/)</a>
  <a href="">[![Downloads](https://pepy.tech/badge/penaltyblog)](https://pepy.tech/badge/penaltyblog)</a>
  <a href="">[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)</a>
  <a href="">[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)</a>
  <a href="">[![Code style: pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white)](https://github.com/pre-commit/pre-commit)</a>

</div>


The **penaltyblog** Python package contains lots of useful code from [pena.lt/y/blog](http://pena.lt/y/blog.html) for working with football (soccer) data.

**penaltyblog** includes functions for:

- Scraping football data from sources such as football-data.co.uk, FBRef, ESPN, Club Elo, Understat, SoFifa and Fantasy Premier League
- Modelling of football matches using Poisson-based models, such as Dixon and Coles, and Bayesian models
- Predicting probabilities for many betting markets, e.g. Asian handicaps, over/under, total goals etc
- Modelling football team's abilities using Massey ratings, Colley ratings and Elo ratings
- Estimating the implied odds from bookmaker's odds by removing the overround using multiple different methods
- Mathematically optimising your fantasy football team

## Installation

`pip install penaltyblog`


## Documentation

To learn how to use penaltyblog, you can read the [documentation](https://penaltyblog.readthedocs.io/en/latest/) and look at the
examples for:

- [Scraping football data](https://penaltyblog.readthedocs.io/en/latest/scrapers/index.html)
- [Predicting football matches and betting markets](https://penaltyblog.readthedocs.io/en/latest/models/index.html)
- [Estimating the implied odds from bookmakers odds](https://penaltyblog.readthedocs.io/en/latest/implied/index.html)
- [Calculate Massey, Colley and Elo ratings](https://penaltyblog.readthedocs.io/en/latest/ratings/index.html)

## References

- Mark J. Dixon and Stuart G. Coles (1997) Modelling Association Football Scores and Inefficiencies in the Football Betting Market
- Håvard Rue and Øyvind Salvesen (1999) Prediction and Retrospective Analysis of Soccer Matches in a League
- Anthony C. Constantinou and Norman E. Fenton (2012) Solving the problem of inadequate scoring rules for assessing probabilistic football forecast models
- Hyun Song Shin (1992) Prices of State Contingent Claims with Insider Traders, and the Favourite-Longshot Bias
- Hyun Song Shin (1993) Measuring the Incidence of Insider Trading in a Market for State-Contingent Claims
- Joseph Buchdahl (2015) The Wisdom of the Crowd
- Gianluca Baio and Marta A. Blangiardo (2010) Bayesian Hierarchical Model for the Prediction of Football Results

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/martineastwood/penaltyblog",
    "name": "penaltyblog",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8,<3.12",
    "maintainer_email": "",
    "keywords": "football,soccer,goals,modelling,dixon coles,poisson,bayesian,scraper,scraping,backtest",
    "author": "Martin Eastwood",
    "author_email": "martin.eastwood@gmx.com",
    "download_url": "https://files.pythonhosted.org/packages/d1/cb/68c1e40a291e6361a6de3901e055fb941d05a92f0d87a67bf9ee15b4a23f/penaltyblog-0.8.0.tar.gz",
    "platform": null,
    "description": "# Penalty Blog\n\n<div align=\"center\">\n\n  <a href=\"\">[![Python Version](https://img.shields.io/pypi/pyversions/penaltyblog)](https://pypi.org/project/penaltyblog/)</a>\n  <a href=\"\">[![Coverage Status](https://coveralls.io/repos/github/martineastwood/penaltyblog/badge.svg?branch=master&service=github)](https://coveralls.io/repos/github/martineastwood/penaltyblog/badge.svg?branch=master&service=github)</a>\n  <a href=\"\">[![PyPI](https://img.shields.io/pypi/v/penaltyblog.svg)](https://pypi.org/project/penaltyblog/)</a>\n  <a href=\"\">[![Downloads](https://pepy.tech/badge/penaltyblog)](https://pepy.tech/badge/penaltyblog)</a>\n  <a href=\"\">[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)</a>\n  <a href=\"\">[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)</a>\n  <a href=\"\">[![Code style: pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white)](https://github.com/pre-commit/pre-commit)</a>\n\n</div>\n\n\nThe **penaltyblog** Python package contains lots of useful code from [pena.lt/y/blog](http://pena.lt/y/blog.html) for working with football (soccer) data.\n\n**penaltyblog** includes functions for:\n\n- Scraping football data from sources such as football-data.co.uk, FBRef, ESPN, Club Elo, Understat, SoFifa and Fantasy Premier League\n- Modelling of football matches using Poisson-based models, such as Dixon and Coles, and Bayesian models\n- Predicting probabilities for many betting markets, e.g. Asian handicaps, over/under, total goals etc\n- Modelling football team's abilities using Massey ratings, Colley ratings and Elo ratings\n- Estimating the implied odds from bookmaker's odds by removing the overround using multiple different methods\n- Mathematically optimising your fantasy football team\n\n## Installation\n\n`pip install penaltyblog`\n\n\n## Documentation\n\nTo learn how to use penaltyblog, you can read the [documentation](https://penaltyblog.readthedocs.io/en/latest/) and look at the\nexamples for:\n\n- [Scraping football data](https://penaltyblog.readthedocs.io/en/latest/scrapers/index.html)\n- [Predicting football matches and betting markets](https://penaltyblog.readthedocs.io/en/latest/models/index.html)\n- [Estimating the implied odds from bookmakers odds](https://penaltyblog.readthedocs.io/en/latest/implied/index.html)\n- [Calculate Massey, Colley and Elo ratings](https://penaltyblog.readthedocs.io/en/latest/ratings/index.html)\n\n## References\n\n- Mark J. Dixon and Stuart G. Coles (1997) Modelling Association Football Scores and Inefficiencies in the Football Betting Market\n- H\u00e5vard Rue and \u00d8yvind Salvesen (1999) Prediction and Retrospective Analysis of Soccer Matches in a League\n- Anthony C. Constantinou and Norman E. Fenton (2012) Solving the problem of inadequate scoring rules for assessing probabilistic football forecast models\n- Hyun Song Shin (1992) Prices of State Contingent Claims with Insider Traders, and the Favourite-Longshot Bias\n- Hyun Song Shin (1993) Measuring the Incidence of Insider Trading in a Market for State-Contingent Claims\n- Joseph Buchdahl (2015) The Wisdom of the Crowd\n- Gianluca Baio and Marta A. Blangiardo (2010) Bayesian Hierarchical Model for the Prediction of Football Results\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Library from http://pena.lt/y/blog for scraping and modelling football (soccer) data",
    "version": "0.8.0",
    "project_urls": {
        "Homepage": "https://github.com/martineastwood/penaltyblog",
        "Repository": "https://github.com/martineastwood/penaltyblog"
    },
    "split_keywords": [
        "football",
        "soccer",
        "goals",
        "modelling",
        "dixon coles",
        "poisson",
        "bayesian",
        "scraper",
        "scraping",
        "backtest"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a50b62882650e224b2b65d2535aca750e862d0d4fb6fb6082d613e074f42943e",
                "md5": "8a4a2602e284ba3c542d443405c7e2ee",
                "sha256": "d7fd6924a0a02eeb3160d5fe72a9218b6ebf7dea9730f99399fe271f80806245"
            },
            "downloads": -1,
            "filename": "penaltyblog-0.8.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "8a4a2602e284ba3c542d443405c7e2ee",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8,<3.12",
            "size": 53637,
            "upload_time": "2023-08-31T18:54:20",
            "upload_time_iso_8601": "2023-08-31T18:54:20.600944Z",
            "url": "https://files.pythonhosted.org/packages/a5/0b/62882650e224b2b65d2535aca750e862d0d4fb6fb6082d613e074f42943e/penaltyblog-0.8.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d1cb68c1e40a291e6361a6de3901e055fb941d05a92f0d87a67bf9ee15b4a23f",
                "md5": "66bfef2809df85b9d1b3f4228e9fb67e",
                "sha256": "66ed5512b637c869dc1f244cae9a1561e1ad8a3ca43ae811f9a77fea390c36b2"
            },
            "downloads": -1,
            "filename": "penaltyblog-0.8.0.tar.gz",
            "has_sig": false,
            "md5_digest": "66bfef2809df85b9d1b3f4228e9fb67e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8,<3.12",
            "size": 32142,
            "upload_time": "2023-08-31T18:54:22",
            "upload_time_iso_8601": "2023-08-31T18:54:22.809337Z",
            "url": "https://files.pythonhosted.org/packages/d1/cb/68c1e40a291e6361a6de3901e055fb941d05a92f0d87a67bf9ee15b4a23f/penaltyblog-0.8.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-08-31 18:54:22",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "martineastwood",
    "github_project": "penaltyblog",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "penaltyblog"
}
        
Elapsed time: 0.27896s