Skip to content
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

Aggregated Data Mismatch? #46

Open
aakar opened this issue Aug 13, 2014 · 1 comment
Open

Aggregated Data Mismatch? #46

aakar opened this issue Aug 13, 2014 · 1 comment

Comments

@aakar
Copy link

aakar commented Aug 13, 2014

I'm trying to get the total passing yards and rushing yards of teams using the agg_play table and manual SQL. Noticing that my summation isn't giving the answers that match the NFL.com DB.

SELECT sum(a.passing_tds) as TD, sum(a.passing_cmp) as PassComp, sum(a.passing_yds) as 
PassYds, sum(a.rushing_yds) as RushYds from agg_play a, drive g, game m where a.drive_id = 
g.drive_id and g.gsis_id = a.gsis_id and g.pos_team = 'NO' and m.gsis_id = g.gsis_id and 
m.season_type = 'Regular' and m.season_year = 2013;

I get the following:

td passcomp passyds rushyds
39 444 5139 1476

NFL.com though has the following
passcomp: 446
passing yds: 4918
rushing yds: 1473

Noticing this with other teams too. I remember reading in the docs that it's likely that some stats may or may not match if they get adjusted by the NFL after the fact, just wondering if that's the case here.

@BurntSushi
Copy link
Owner

It's not that stats get adjusted, it's that the JSON feed can just be inaccurate. Usually it's a result of missing data, so that aggregating usually results in underestimates. That you have overestimates is strange. It warrants more investigation.

Investigation is tedious, because it means pinpointing more precisely where the errors are coming from. Usually they are spread out over many games, but sometimes you'll find a pocket of errors for one game.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants