A python script to pull FPL manager season data from the Fantasy Premier League API.
For use:
- Generate necessary data files for FPL Season Review Tableau dashboard.
- A starting point for other FPL data exploration and visualization needs.
git clone https://github.com/njgootee/FPL_season_review
Or just download the get_msd.py file.
Required libraries:
- pandas
- requests
- Navigate to directory where get_msd.py is saved.
- Run:
python get_msd.py {fpl_id}
-
On the FPL Website login and navigate to the 'Points' tab.
-
Your FPL ID is within the URL as following: fantasy.premierleague.com/entry/{fpl_id}/event/{gameweek}
A 'data' directory will be created and populated with 4 files:
- current.csv
- Current season overview stats including ranks, points, value, transfers, chip usage.
- gameweeks.csv
- Gameweeks team selection data.
- seasons.csv
- Past seasons finishes overall ranks and points.
- transfers.csv
- Gameweek transfered players in and out.