Comments (1)
Hey @Zatfer17 since the package is just scraping Understat's website it's not always possible to mimic their functionality. The filtering they do on the website is done on their backend so we can't do the same, but you can you can always filter it manually yourself (probably best) or by using any of the keys as shown in the documentation:
async def main():
async with aiohttp.ClientSession() as session:
understat = Understat(session)
results = await understat.get_team_players(
"Manchester United",
2018,
position="F S"
)
print(json.dumps(results))
loop = asyncio.get_event_loop()
loop.run_until_complete(main())
[
{
"id": "594",
"player_name": "Romelu Lukaku",
"games": "27",
"time": "1768",
"goals": "12",
"xG": "12.054240763187408",
"assists": "0",
"xA": "1.6836179178208113",
"shots": "50",
"key_passes": "17",
"yellow_cards": "4",
"red_cards": "0",
"position": "F S",
"team_title": "Manchester United",
"npg": "12",
"npxG": "12.054240763187408",
"xGChain": "12.832402393221855",
"xGBuildup": "3.366600174456835"
}
]
from understat.
Related Issues (17)
- Pulling Match Events Other Than Goals HOT 4
- Apply filters on tables HOT 1
- run time error HOT 5
- Pull additional data for each match HOT 5
- UnboundLocalError
- feat: Building Conda Packages
- ci: Create Basic CI/CD pipeline using Github Actions
- 'NoneType' object has no attribute 'group' HOT 5
- Example in the readme is not working HOT 1
- Possible issue on Anaconda HOT 4
- Fixtures not working? HOT 1
- Add endpoint for individual match stats
- Replace BeautifulSoup with lxml or similar
- Tests don't all pass off-season HOT 1
- Only last week HOT 3
- error messages HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from understat.