nflverse / nflfastR

A Set of Functions to Efficiently Scrape NFL Play by Play Data
https://www.nflfastr.com/
Other
414 stars 50 forks source link

no kick off if previous play is weather delay #461

Closed mrcaseb closed 6 months ago

mrcaseb commented 6 months ago

There is this logic where we set kickoff_attempt to 1 mostly for plays with penalties.

The logic uses previous play data and skips the kickoff_attempt in various situations. The logic includes that we skip a kickott_attempt if the play description of the previous play says "The game has resumed" after it has been suspended for whatever reason.

However, in 2023_13_ARI_PIT the games has been suspended twice and after the second one there ways no "The game has resumed" which made the logic set kickoff_attempt == 1 and ultimately resulted in wrong fixed_drive numbers (#447).

This PR explicitly avoids kickoff_attempt if the previous play description says "game has been suspended". This fixes #447 but it might fail in the future if the "The game has resumed" play is missing and the play description varies for some reason.

github-actions[bot] commented 6 months ago

🚀 Deployed on https://65e9a58af6ea410088bd72c2--thirsty-brown-d38ddf.netlify.app