Skip to contents

phf_game_all: pull in the raw data for a game_id from the PHF/NWHL API

Usage

phf_game_all(game_id)

Arguments

game_id

The unique ID code for the game that you are interested in viewing the data for

Value

A named list of data frames: plays, team_box, skaters, goalies, game_details, scoring_summary, shootout_summary, penalty_summary, officials, team_staff, timeouts

Examples

# \donttest{
  try(phf_game_all(game_id = 612254))
#> $plays
#> ── PHF Play-by-Play Information from PremierHockeyFederation.com ───────────────
#>  Data updated: 2023-03-08 07:47:52 UTC
#> # A tibble: 195 × 79
#>    play_type team  time  play_…¹ scori…² scori…³ offen…⁴ offen…⁵ offen…⁶ offen…⁷
#>    <chr>     <chr> <chr> <chr>   <chr>   <chr>   <chr>   <chr>   <chr>   <chr>  
#>  1 Goalie    Metr… 00:00 Starti… NA      NA      NA      NA      NA      NA     
#>  2 Goalie    Toro… 00:00 Starti… NA      NA      NA      NA      NA      NA     
#>  3 Faceoff   Toro… 00:05 #27 Sh… NA      NA      NA      NA      NA      NA     
#>  4 Giveaway  Toro… 00:40 #27 Sh… NA      NA      NA      NA      NA      NA     
#>  5 Shot      Metr… 00:42 #77 Ke… NA      NA      NA      NA      NA      NA     
#>  6 Faceoff   Metr… 00:48 #77 Ke… NA      NA      NA      NA      NA      NA     
#>  7 Shot      Toro… 01:15 #41 Br… NA      NA      NA      NA      NA      NA     
#>  8 Faceoff   Metr… 01:25 #28 Le… NA      NA      NA      NA      NA      NA     
#>  9 Shot      Toro… 02:40 #67 Em… NA      NA      NA      NA      NA      NA     
#> 10 Faceoff   Metr… 02:42 #16 Sa… NA      NA      NA      NA      NA      NA     
#> # … with 185 more rows, 69 more variables: offensive_player_name_5 <chr>,
#> #   offensive_player_name_6 <chr>, defending_team_abbrev <chr>,
#> #   defending_team_on_ice <chr>, defensive_player_name_1 <chr>,
#> #   defensive_player_name_2 <chr>, defensive_player_name_3 <chr>,
#> #   defensive_player_name_4 <chr>, defensive_player_name_5 <chr>,
#> #   defensive_player_name_6 <chr>, period_id <int>, game_id <dbl>,
#> #   game_date <chr>, home_team <chr>, home_location <chr>, …
#> 
#> $team_box
#> ── PHF Team Box Information from PremierHockeyFederation.com ───────────────────
#>  Data updated: 2023-03-08 07:47:52 UTC
#> # A tibble: 2 × 25
#>   team  game_id winner total_s…¹ succe…² power…³ power…⁴ penal…⁵ faceo…⁶ block…⁷
#>   <chr>   <dbl> <lgl>      <int>   <dbl>   <dbl>   <dbl>   <dbl>   <dbl>   <dbl>
#> 1 met    612254 TRUE           3       0       5     0         6   0.516      13
#> 2 tor    612254 FALSE          2       2       4     0.5      10   0.484      11
#> # … with 15 more variables: takeaways <dbl>, giveaways <dbl>,
#> #   period_1_shots <int>, period_2_shots <int>, period_3_shots <int>,
#> #   overtime_shots <int>, shootout_made_shots <int>,
#> #   shootout_missed_shots <int>, total_shots <int>, period_1_scoring <int>,
#> #   period_2_scoring <int>, period_3_scoring <int>, overtime_scoring <int>,
#> #   shootout_made_scoring <dbl>, shootout_missed_scoring <dbl>, and abbreviated
#> #   variable names ¹​total_scoring, ²​successful_power_play, …
#> 
#> $skaters
#> ── PHF Skaters Boxscore Information from PremierHockeyFederation.com ───────────
#>  Data updated: 2023-03-08 07:47:56 UTC
#> # A tibble: 35 × 23
#>    player_…¹ playe…² posit…³ goals assists points penal…⁴ shots…⁵ blocks givea…⁶
#>        <int> <chr>   <chr>   <int>   <int>  <int>   <int>   <int>  <int>   <int>
#>  1        10 Lexi T… F           0       1      1       0       0      0       0
#>  2        11 Breann… F           0       1      1       0       1      1       0
#>  3        41 Britta… F           1       0      1       0       5      2       2
#>  4        67 Emma W… F           0       1      1       0       5      1       0
#>  5        86 Michel… F           0       1      1       2       2      0       0
#>  6        96 Domini… D           1       0      1       0       3      1       1
#>  7         3 Nadine… F           0       0      0       0       0      0       0
#>  8         8 Leah L… F           0       0      0       0       1      0       0
#>  9         9 Kati T… D           0       0      0       0       2      1       2
#> 10        14 Courtn… F           0       0      0       2       1      0       0
#> # … with 25 more rows, 13 more variables: takeaways <int>,
#> #   faceoffs_won_lost <chr>, faceoffs_win_pct <dbl>, powerplay_goals <int>,
#> #   shorthanded_goals <int>, shots <int>, shots_blocked <int>,
#> #   faceoffs_won <int>, faceoffs_lost <int>, team <chr>, skaters_href <chr>,
#> #   player_id <chr>, game_id <dbl>, and abbreviated variable names
#> #   ¹​player_jersey, ²​player_name, ³​position, ⁴​penalty_minutes, ⁵​shots_on_goal,
#> #   ⁶​giveaways
#> 
#> $goalies
#> ── PHF Goalies Boxscore Information from PremierHockeyFederation.com ───────────
#>  Data updated: 2023-03-08 07:47:56 UTC
#> # A tibble: 4 × 14
#>   player_j…¹ playe…² shots…³ goals…⁴ saves save_…⁵ minut…⁶ penal…⁷ goals assists
#>        <int> <chr>     <int>   <int> <int>   <dbl> <chr>     <int> <int>   <int>
#> 1         29 Elaine…      38       2    36   0.947 65:00         0     0       0
#> 2         70 Carly …       0       0     0   0     00:00         0     0       0
#> 3          1 Evelii…       0       0     0   0     00:00         0     0       0
#> 4         88 Katie …      32       2    30   0.938 65:00         0     0       0
#> # … with 4 more variables: team <chr>, goalies_href <chr>, player_id <chr>,
#> #   game_id <dbl>, and abbreviated variable names ¹​player_jersey, ²​player_name,
#> #   ³​shots_against, ⁴​goals_against, ⁵​save_percent, ⁶​minutes_played,
#> #   ⁷​penalty_minutes
#> 
#> $game_details
#> ── PHF Game Details Information from PremierHockeyFederation.com ───────────────
#>  Data updated: 2023-03-08 07:47:51 UTC
#> # A tibble: 1 × 12
#>   game_id game_date      home_…¹ home_…² home_…³ home_…⁴ home_…⁵ away_…⁶ away_…⁷
#>     <dbl> <chr>          <chr>   <chr>   <chr>   <chr>     <int> <chr>   <chr>  
#> 1  612254 Dec 10, 2022 … Toront… Toronto Six     TOR           2 Metrop… Metrop…
#> # … with 3 more variables: away_nickname <chr>, away_abbreviation <chr>,
#> #   away_score_total <int>, and abbreviated variable names ¹​home_team,
#> #   ²​home_location, ³​home_nickname, ⁴​home_abbreviation, ⁵​home_score_total,
#> #   ⁶​away_team, ⁷​away_location
#> 
#> $scoring_summary
#> ── PHF Game Scoring Summary Information from PremierHockeyFederation.com ───────
#>  Data updated: 2023-03-08 07:47:59 UTC
#> # A tibble: 4 × 6
#>   period time  strength team                  scorer_assists               total
#>   <chr>  <chr> <chr>    <chr>                 <chr>                        <chr>
#> 1 1st    11:31 ES       Metropolitan Riveters Amanda Pelkey                1 - …
#> 2 1st    12:17 PP       Toronto Six           Dominika Lásková (Lexi Temp… 1 - …
#> 3 2nd    11:40 ES       Metropolitan Riveters Reagan Rust (Kelly Babstock… 2 - …
#> 4 2nd    16:30 PP       Toronto Six           Brittany Howard (Michela Ca… 2 - …
#> 
#> $shootout_summary
#> ── PHF Game Shootout Summary Information from PremierHockeyFederation.com ──────
#>  Data updated: 2023-03-08 07:47:59 UTC
#> # A tibble: 3 × 6
#>   round metropolitan_riveters   scored toronto_six            scored_2 total
#>   <int> <chr>                   <chr>  <chr>                  <chr>    <chr>
#> 1     1 "Fanni Garát-Gasparics" "No"   Dominika Lásková       No       0 - 0
#> 2     2 "Minttu Tuominen"       "Yes"  Brittany Howard        No       1 - 0
#> 3     3 ""                      ""     Breanne Wilson-Bennett No       1 - 0
#> 
#> $penalty_summary
#> ── PHF Game Penalty Summary Information from PremierHockeyFederation.com ───────
#>  Data updated: 2023-03-08 07:47:59 UTC
#> # A tibble: 9 × 6
#>   period time  player                    team                  infraction length
#>   <chr>  <chr> <chr>                     <chr>                 <chr>      <chr> 
#> 1 1st    09:23 Amanda Pelkey             Metropolitan Riveters Tripping … 02:00 
#> 2 1st    12:05 Served by Kaycie Anderson Metropolitan Riveters Too Many … 02:00 
#> 3 1st    13:09 Alexis Woloschuk          Toronto Six           Tripping … 02:00 
#> 4 1st    19:55 Ebba Berglund             Metropolitan Riveters Tripping … 02:00 
#> 5 2nd    07:43 Brooke Boquist            Toronto Six           Hooking (… 02:00 
#> 6 2nd    14:51 Sarah Bujold              Metropolitan Riveters Boarding … 02:00 
#> 7 2nd    18:19 Courtney Gardiner         Toronto Six           Roughing … 02:00 
#> 8 3rd    14:05 Michela Cava              Toronto Six           Holding (… 02:00 
#> 9 OT1    04:27 Shiann Darkangelo         Toronto Six           Tripping … 02:00 
#> 
#> $officials
#> ── PHF Game Officials Information from PremierHockeyFederation.com ─────────────
#>  Data updated: 2023-03-08 07:47:59 UTC
#> # A tibble: 0 × 0
#> 
#> $team_staff
#> ── PHF Game Team Staff Information from PremierHockeyFederation.com ────────────
#>  Data updated: 2023-03-08 07:47:59 UTC
#> # A tibble: 0 × 0
#> 
#> $timeouts
#> ── PHF Game Timeouts Information from PremierHockeyFederation.com ──────────────
#>  Data updated: 2023-03-08 07:47:59 UTC
#> # A tibble: 1 × 3
#>   team                  period time 
#>   <chr>                 <chr>  <chr>
#> 1 Metropolitan Riveters OT1    00:33
#> 
# }