Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Incorrect EPA Value #175

Closed
ConnerEvans opened this issue Feb 6, 2021 · 4 comments · Fixed by #176
Closed

Incorrect EPA Value #175

ConnerEvans opened this issue Feb 6, 2021 · 4 comments · Fixed by #176

Comments

@ConnerEvans
Copy link

For game_id == ‘2019_08_OAK_HOU’ play_id’s 1674, 1710, and 1750 are consecutive plays.
ep_1674 + epa_1674 != -ep_1710 (negative because change of possession)

Other information about the values that may help in debugging:
ep_1674 + epa_1674 = -ep_1750
ep_1710 + epa_1710 = ep_1750

ep_1674 = -1.85264738, epa_1674 = 1.51558956,
ep_1710 = 1.33986175, epa_1710 = -1.00280392
ep_1750 = 0.33705783

desc_1674 = (7:12) 9-B.Anger punts 49 yards to OAK 35, Center-46-J.Weeks. 11-T.Davis to OAK 38 for 3 yards (57-B.Scarlett). PENALTY on OAK-32-D.Leavitt, Offensive Holding, 10 yards, enforced at OAK 38. Punt Hangtime: 4.69s

desc_1710 = (7:01) (Shotgun) 4-D.Carr pass deep left to 83-D.Waller pushed ob at HOU 42 for 30 yards (27-M.Adams). PENALTY on OAK-13-H.Renfrow, Offensive Pass Interference, 10 yards, enforced at OAK 28 - No Play. Oakland challenged the offensive pass interference ruling, and the play was Upheld. The ruling on the field stands. (Timeout #2.)

@ConnerEvans
Copy link
Author

I found another example: game_id == '2019_05_IND_KC', play_id == 3554, desc = (15:00) (Shotgun) 7-J.Brissett pass short left to 84-J.Doyle to KC 28 for 12 yards (20-M.Claiborne). PENALTY on IND-13-T.Hilton, Offensive Pass Interference, 10 yards, enforced at KC 40 - No Play. Indianapolis challenged the offensive pass interference ruling, and the play was Upheld. The ruling on the field stands. (Timeout #2.)

I think it might be because of some combination of there being a penalty, no_play, and/or a challenge that resulted in the play being upheld.

@ConnerEvans
Copy link
Author

2019_02_TB_CAR, 386, (8:40) (Shotgun) 1-C.Newton right end to TB 47 for no gain (31-J.Whitehead). Carolina challenged the short of the line to gain ruling, and the play was Upheld. The ruling on the field stands. (Timeout #1 at 08:31.)

@guga31bb
Copy link
Member

guga31bb commented Feb 6, 2021

library(tidyverse)
pbp <- readRDS(url(glue::glue("https://raw.githubusercontent.com/guga31bb/nflfastR-data/master/data/play_by_play_2019.rds")))
pbp %>% filter(game_id == '2019_05_IND_KC', between(play_id, 3500, 3600)) %>% select(posteam, down, ydstogo, desc, ep, epa) %>% View

image

@guga31bb guga31bb linked a pull request Feb 6, 2021 that will close this issue
@guga31bb
Copy link
Member

guga31bb commented Feb 6, 2021

Yep the first 2 were related to failed challenges on pass interference (which is why they're all in 2019). The last one is because a weather delay added a bunch of blank rows after the play. Thanks for finding these!

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

Successfully merging a pull request may close this issue.

2 participants