A Python library designed for developers and analysts to calculate betting odds with ease using the power of Poisson distribution based on team qualities.
Project description
Odds by Poisson Distribution
This library enables the calculation of betting odds (moneyline, handicaps, totals) based on team qualities using the Poisson distribution.
It provides a simple interface for initializing calculations, requiring only the qualities of both teams. These qualities can be obtained using metrics such as expected goals (xG) or average number of goals.
Installation
pip install poisson-odds
Usage Example
from poisson_odds import *
test = Poisson(1.1, 2.1)
test.print_probability_table_goal_draws()
### Output:
print(test.moneyline)
### Output:
1-X-2: 5.291-4.878-1.669
handicaps = test.calculate_handicap_odds_by_Poisson()
print('\n'.join([str(items) for key, items in handicaps.items()]))
### Output:
...
0.75: 2.206 / 1.879
1.0: 1.918 / 2.089
1.25: 1.75 / 2.403
1.5: 1.582 / 2.717
...
totals = test.calculate_total_odds_by_Poisson()
print('\n'.join([str(items) for key, items in totals.items()]))
### Output:
...
Over/Under 2.75: 1.788 / 2.333
Over/Under 3: 1.961 / 2.04
Over/Under 3.25: 2.243 / 1.848
Over/Under 3.5: 2.525 / 1.656
...
Demonstrating
A real-world example of using the 'poisson_odds' library to analyze actual NHL odds by comparing them to probabilities based on expected goals (xG).
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file poisson_odds-0.1.3.tar.gz.
File metadata
- Download URL: poisson_odds-0.1.3.tar.gz
- Upload date:
- Size: 11.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8b763743a38e48bc0f0fb64f046cb6196aab4e3278542182601c14202158accf
|
|
| MD5 |
223ea5dcd72fea1ef33b880d4478311a
|
|
| BLAKE2b-256 |
5ca1db0ffe813daed2e15bffc943d63ee19c4d928f435a6c95913ee98e6cbac5
|
File details
Details for the file poisson_odds-0.1.3-py3-none-any.whl.
File metadata
- Download URL: poisson_odds-0.1.3-py3-none-any.whl
- Upload date:
- Size: 11.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
233e4eaa9108652e5a35d20da1ee09c95af4e52297cd77880ddcf6cfb3de5086
|
|
| MD5 |
b43d57b9f3f4b76ed5bded385400ff69
|
|
| BLAKE2b-256 |
330f047b471e4639ed9d569e5eb725d487066b74f828966fe7fc1a6bf3e91c5a
|