
Strip the game ID into the season ID, game type ID, and game number for all the events (plays) in a play-by-play
Source:R/Clean.R
strip_game_id.Rdstrip_game_id() strips the game ID into the season ID, game type ID, and
game number for all the events (plays) in a play-by-play.
Arguments
- play_by_play
data.frame of play-by-play(s); see
gc_play_by_play()and/orwsc_play_by_play()for reference; must be untouched by non-nhlscraper functions
Value
data.frame with one row per event (play) and added columns:
seasonId, gameTypeId, and gameNumber
Examples
# May take >5s, so skip.
# \donttest{
test <- gc_play_by_play()
test_game_id_stripped <- strip_game_id(test)
# }