cwendt94 / espn-api

ESPN Fantasy API! (Football, Basketball)
MIT License
544 stars 183 forks source link

Add yearly nine_cat_averages to Player #447

Closed johncheng2011 closed 1 year ago

johncheng2011 commented 1 year ago

This adds a property to Player that shows the yearly averages for common categories used in 9-cat leagues.

I've been really liking using this library to do some more digging into my league, and it'll be great to get easier access to category averages. So this PR gets closer to that, but let me know if there are any issues with adding this. Thanks!

codecov-commenter commented 1 year ago

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.05 :tada:

Comparison is base (68224a5) 80.31% compared to head (0802aee) 80.36%.

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #447 +/- ## ========================================== + Coverage 80.31% 80.36% +0.05% ========================================== Files 60 60 Lines 2103 2109 +6 ========================================== + Hits 1689 1695 +6 Misses 414 414 ``` | [Impacted Files](https://codecov.io/gh/cwendt94/espn-api/pull/447?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Christian+Wendt) | Coverage Δ | | |---|---|---| | [espn\_api/basketball/constant.py](https://codecov.io/gh/cwendt94/espn-api/pull/447?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Christian+Wendt#diff-ZXNwbl9hcGkvYmFza2V0YmFsbC9jb25zdGFudC5weQ==) | `100.00% <100.00%> (ø)` | | | [espn\_api/basketball/player.py](https://codecov.io/gh/cwendt94/espn-api/pull/447?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Christian+Wendt#diff-ZXNwbl9hcGkvYmFza2V0YmFsbC9wbGF5ZXIucHk=) | `100.00% <100.00%> (ø)` | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Christian+Wendt). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Christian+Wendt)

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

cwendt94 commented 1 year ago

Thanks for submitting this PR! I like the idea of adding some helper functions to make it easier getting certain data depending on the league scoring type.