Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/statsbomb/socplot
Python package that helps you visualize football data :soccer:
https://github.com/statsbomb/socplot
data-visualization football-data
Last synced: 3 months ago
JSON representation
Python package that helps you visualize football data :soccer:
- Host: GitHub
- URL: https://github.com/statsbomb/socplot
- Owner: statsbomb
- Created: 2019-01-06T16:19:03.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2019-01-06T19:53:56.000Z (almost 6 years ago)
- Last Synced: 2024-07-28T04:09:07.363Z (3 months ago)
- Topics: data-visualization, football-data
- Language: Python
- Size: 433 KB
- Stars: 61
- Watchers: 8
- Forks: 10
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: docs/CONTRIBUTING.md
- Code of conduct: docs/code-of-conduct.md
Awesome Lists containing this project
- awesome-football-analytics - Socplot
README
# Socplot
Socplot is a python 3 package that helps you visualize football data. __[WIP]__
## Why Socplot?
- Made by [football enthusiast](www.arqamfc.com).
- Fully configurable in terms of dimensions, colors and types.
- Lightweight and Flexibility: Socplot is built on top of matplotlib. You have full control.
- Straightforward: Socplot has many built in figures that gets you directly to the point.## Gallery
__Pressure heat map__
pressures position heat map for an example match
![](https://raw.githubusercontent.com/ArqamFC/socplot/master/docs/gallery/heatmap1.png)![](https://raw.githubusercontent.com/ArqamFC/socplot/master/docs/gallery/heatmap2.png)
__Pass map__
pass map for selected time window in an example match
![](https://github.com/ArqamFC/socplot/blob/master/docs/gallery/pass_map1.png)first 15 mins passes in an example match
![](https://github.com/ArqamFC/socplot/blob/master/docs/gallery/pass_map2.png)## Example
```python
code snippet used to generate the last image
import pandas as pd
from socplot.pitch import Pitchpitch = Pitch()
# load the passes dataset
for _, row in passes.iterrows():
pitch.plot_pass(row['sx'], row['sy']],[row['ex'], row['ey']] , row['type'])pitch.heat_map(df['sx'], df['sx'], color='tan')
```__
## Installation
pip installtion coming soon
## Dev Installation
```shell
# fork the repo
cd socplot
virtualenv -p python3 env
source env/bin/activate
pip install -r requirements.txt
```## LICENCE
ArqamFc/Socplot licensed under the __Apache License 2.0__.