Comments (1)
Hi @stranger9977, it appears the data is present in the repo as intended.
In: pd.merge(
...: nfl.import_rosters([2022]),
...: nfl.import_seasonal_data([2022]),
...: on=['season', 'player_id']
...: ).query('player_name == "Drake London"')
Out:
season team position depth_chart_position jersey_number status player_name first_name last_name birth_date height weight college ... games tgt_sh ay_sh yac_sh wopr_y ry_sh rtd_sh rfd_sh rtdfd_sh dom w8dom yptmpa ppr_sh
40 2022 ATL WR WR 5.0 Active Drake London Drake London 2001-07-24 76.0 210.0 None ... 17 0.281928 0.300521 0.187958 0.663308 0.295866 0.235294 0.324324 0.315152 0.26558 0.283752 2.086747 0.149509
[1 rows x 92 columns]
The problem is in your line stats['season'] = stats['season'] +1
. I'm not sure what your intention was exactly, but doing that sets London's one year of seasonal_data as if it happened in 2023 instead of 2022. Since there is no 2023 roster data published yet, your pd.merge
with how='inner'
filters London out since there are no records that align on season.
Hope this helps! Feel free to ask any follow-up questions.
from nfl_data_py.
Related Issues (20)
- import_combine_data() breaks with positions and no years param
- Not up to date HOT 7
- import_weekly_rosters HOT 1
- weekly pfr and ftn data HOT 2
- get_team_game_log doesn't return game results for current season HOT 2
- Error with python-snappy HOT 3
- AttributeError: module 'nfl_data_py' has no attribute 'import_seasonal_pfr' HOT 2
- import_weekly_data returns shortened list HOT 2
- Help - Novice here HOT 8
- Play_clock is set to 0 for all of 2023
- Indexing Issue With import_weekly_rosters HOT 1
- ReadMe says play-byplay data, does this api have live endpoints?
- python-snappy issue persisting HOT 10
- snappy issue HOT 3
- import_sc_lines only updated to 2020
- import_injuries only has 2023 data up until week 19
- Depth Chart Issues
- Unable to install 0.3.1 package when using PyCharm CE 2023.3.3 and Python v3.12.2
- PBP data not available for 2022
- [BUG] import_schedule shows wrong week for rest HOT 2
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 nfl_data_py.