Metadata-Version: 2.4
Name: eplda
Version: 0.2.2
Summary: An unofficial lightweight Python client library for Premier League Data API
Home-page: https://github.com/zhouyuyang-joey/English-Premier-League-Data-API
Author: Zhou Yuyang
Author-email: joeyjoeyjoemail@163.com
Project-URL: Bug Reports, https://github.com/zhouyuyang-joey/English-Premier-League-Data-API/issues
Project-URL: Source, https://github.com/zhouyuyang-joey/English-Premier-League-Data-API
Project-URL: Documentation, https://github.com/zhouyuyang-joey/English-Premier-League-Data-API/blob/main/README.md
Keywords: premier-league football soccer api data statistics
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: Scientific/Engineering :: Information Analysis
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: requests
Requires-Dist: pandas
Provides-Extra: dev
Requires-Dist: pytest; extra == "dev"
Requires-Dist: pytest-cov; extra == "dev"
Requires-Dist: black; extra == "dev"
Requires-Dist: flake8; extra == "dev"
Provides-Extra: test
Requires-Dist: pytest; extra == "test"
Requires-Dist: pytest-mock; extra == "test"
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: home-page
Dynamic: keywords
Dynamic: license-file
Dynamic: project-url
Dynamic: provides-extra
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# ⚽ English-Premier-League-Data-API

`EPL-Data` is an unofficial lightweight Python API client for [www.premierleague.com](https://www.premierleague.com/), providing quick access to data on Premier League players and clubs. It is ideal for data analysis and visualization.

**Note:** This project is for personal interest and learning only. Commercial use is strictly not permitted.


## Features
- ✅ Super user-friendly (hopefully)
- ✅ Player and club data access
- ✅ Supports both JSON and pandas DataFrame output formats
- ✅ Live Data

## What's New with version 0.2.2
- Improved documentation and usage examples
- Self-explanatory naming
- More robust error handling and clearer API responses
- Expanded notebook example with step-by-step usage and visualization


## Installation
The easiest way to install the latest version is:
```
pip install eplda
```

## Quick Start Guide
Get the season ID for a specific season:
```python
from eplda import EPLAPI

epl = EPLAPI()
season_id = epl.get_season_id("2024/25")
```

Get the top scorer's list and convert it to a pandas DataFrame:
```python
df_goals = epl.get_player_rankings("goals", season_id, output="df")
```

Search for a player ID by name and get player information:
```python
player_id = epl.get_player_id("Erling Haaland", season_id)
player_info = epl.get_player_details(player_id, season_id)
```

## Example Notebook
A comprehensive demonstration is available in [examples.ipynb](examples.ipynb), including:

- Brief explanation of all methods
- Club and player data queries
- Data visualization

## Known Issues
- For some reason, some players cannot be found by ``search_player_by_name()`` or ``get_player_list()``.
(The temporary solution is to read the player's ID in the URL of the official website, e.g. Bukayo Saka's ID is [49481](https://www.premierleague.com/players/49481/Bukayo-Saka/overview))

## License & Terms of Use

### API Client

The `eplda` is open source with an [MIT License](LICENSE).

### T&C

``www.premierleague.com`` has a [Terms and Conditions](https://www.premierleague.com/terms-and-conditions) regarding the INTELLECTUAL PROPERTY RIGHTS. 

Please note that this project has been created for research purposes only and should not be misused in any way with this project or the data obtained from this it.

## Acknowledgement 
This project is based on Erick Ghuron's [premier-league-data](https://github.com/ghurone/premier-league-data).
