-
Notifications
You must be signed in to change notification settings - Fork 263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Time accurate player-on-team data #176
Comments
All depends on how you're querying the data. You could do something like this: import nfldb
db = nfldb.connect()
q = nfldb.Query(db)
q.game(season_year=2009, week=1, season_type='Regular', team='MIN')
for pp in q.as_play_players():
print 'Player:', pp.player
print '\tTeam at time of game:', pp.team # Use this to get the player's team
print '\tCurrent team:', pp.player.team # Not this which would get the player's current team
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Been digging through nfldb recently. Really easy to understand & powerful tool. Great work! One thing I noticed is that when querying past data (ie 2015 stats) that player data returns with their current (2016) team information. For example:
(43, 'Zach Mettenberger (PIT, QB)'),
Despite a 2015 game query, it thinks that ZM is on PIT, which didn't happen until 2016. I'd imagine this issue propagates further back as well when players change teams? Is there any way to link time-accurate team-player data?
edit:
I see this was also discussed here but solution was never reached #157
The text was updated successfully, but these errors were encountered: