Skip to contents

phf_player_stats: loads the player stats

Usage

phf_player_stats(player_id)

Arguments

player_id

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

Value

A named list of data frames: career, game_log

Examples

# \donttest{
  try(phf_player_stats(player_id = 431611))
#> $career
#> ── PHF Goalies Yearly Stats Information from PremierHockeyFederation.com ───────
#>  Data updated: 2023-03-08 07:48:26 UTC
#> # A tibble: 7 × 26
#>   season   team_…¹ divis…²    GP     W     L     T   OTL minut…³ shots…⁴ goals…⁵
#>   <chr>    <chr>   <chr>   <int> <int> <int> <int> <int> <chr>     <int>   <int>
#> 1 "2021-2… "Bosto… "PHF"       4     1     1     0     1 194:18       79       9
#> 2 "2020-2… "Bosto… "NWHL"      7     1     1     0     0 131:53       62       5
#> 3 "2019-2… "Bosto… "NWHL"     24     6     0     0     0 396:24      161      13
#> 4 ""       ""      ""         35     8     2     0     1 722:35      302      27
#> 5 "2020-2… "Bosto… "NWHL"      2     0     0     0     0 00:00         0       0
#> 6 "2019-2… "Bosto… "NWHL"      1     0     0     0     0 00:00         0       0
#> 7 ""       ""      ""          3     0     0     0     0 00:00         0       0
#> # … with 15 more variables: save_percent <dbl>, GAA <dbl>, SO <int>,
#> #   saves <int>, penalty_minutes <int>, goals <int>, assists <int>, GS <int>,
#> #   player_name <chr>, player_id <dbl>, position <chr>,
#> #   player_image_href <chr>, team_href <chr>, season_type <chr>, team_id <int>,
#> #   and abbreviated variable names ¹​team_name, ²​division, ³​minutes_played,
#> #   ⁴​shots_against, ⁵​goals_against
#> 
#> $game_log
#> ── PHF Goalies Game Log Stats Information from PremierHockeyFederation.com ─────
#>  Data updated: 2023-03-08 07:48:26 UTC
#> # A tibble: 48 × 17
#>    date  game  shots…¹ goals…² saves save_…³ minut…⁴ penal…⁵ goals assists Pos  
#>    <chr> <chr>   <int>   <int> <int>   <dbl> <chr>     <int> <int>   <int> <chr>
#>  1 Marc… Prid…       0       0     0   0     00:00         0     0       0 Goal…
#>  2 Marc… Prid…      25       4    21   0.84  62:11         0     0       0 Goal…
#>  3 Marc… Prid…       0       0     0   0     00:00         0     0       0 Goal…
#>  4 Marc… Prid…       0       0     0   0     00:00         0     0       0 Goal…
#>  5 Febr… Beau…       0       0     0   0     00:00         0     0       0 Goal…
#>  6 Febr… Beau…       0       0     0   0     00:00         0     0       0 Goal…
#>  7 Febr… Whal…      10       3     7   0.7   30:52         0     0       0 Goal…
#>  8 Janu… Rive…      18       1    17   0.944 40:00         0     0       0 Goal…
#>  9 Dece… Six …       0       0     0   0     00:00         0     0       0 Goal…
#> 10 Nove… Prid…      26       1    25   0.962 61:15         0     0       0 Goal…
#> # … with 38 more rows, 6 more variables: player_name <chr>, player_id <dbl>,
#> #   position <chr>, player_image_href <chr>, game_href <chr>, game_id <int>,
#> #   and abbreviated variable names ¹​shots_against, ²​goals_against,
#> #   ³​save_percent, ⁴​minutes_played, ⁵​penalty_minutes
#> 
  try(phf_player_stats(player_id = 532475))
#> $career
#> ── PHF Skaters Yearly Stats Information from PremierHockeyFederation.com ───────
#>  Data updated: 2023-03-08 07:48:27 UTC
#> # A tibble: 10 × 30
#>    season   team_…¹ divis…² games…³ goals assists points shots…⁴ faceo…⁵ faceo…⁶
#>    <chr>    <chr>   <chr>     <int> <int>   <int>  <int>   <int> <chr>     <int>
#>  1 "2022-2… "PHF C… "All-S…       3     0       1      1       1 0 - 0         0
#>  2 "2022-2… "Buffa… "PHF"        22     8      10     18      72 195 - …     195
#>  3 "2021-2… "Toron… "PHF"        19    13      17     30      96 164 - …     164
#>  4 "2020-2… "Toron… "NWHL"        6     5       4      9      28 22 - 14      22
#>  5 "2019-2… "Buffa… "NWHL"        2     2       1      3       8 25 - 16      25
#>  6 ""       ""      ""           52    28      33     61     205 406.0 …     406
#>  7 "2021-2… "Toron… "PHF"         1     0       0      0       6 6 - 5         6
#>  8 "2020-2… "Toron… "NWHL"        1     1       1      2       3 2 - 1         2
#>  9 "2019-2… "Buffa… "NWHL"        1     1       1      2       2 9 - 12        9
#> 10 ""       ""      ""            3     2       2      4      11 17.0 -…      17
#> # … with 20 more variables: faceoffs_lost <int>, blocks <int>,
#> #   penalty_minutes <int>, takeaways <int>, giveaways <int>, scoring_pct <dbl>,
#> #   powerplay_goals <int>, shorthanded_goals <int>, game_winning_goals <int>,
#> #   points_per_game_average <dbl>, faceoffs_win_pct <dbl>, shots_blocked <int>,
#> #   shots <int>, player_name <chr>, player_id <dbl>, position <chr>,
#> #   player_image_href <chr>, team_href <chr>, season_type <chr>, team_id <int>,
#> #   and abbreviated variable names ¹​team_name, ²​division, ³​games_played, …
#> 
#> $game_log
#> ── PHF Skaters Game Log Stats Information from PremierHockeyFederation.com ─────
#>  Data updated: 2023-03-08 07:48:27 UTC
#> # A tibble: 62 × 27
#>    date  game  Pos   goals assists points penal…¹ shots…² blocks givea…³ takea…⁴
#>    <chr> <chr> <chr> <int>   <int>  <int>   <int>   <int>  <int>   <int>   <int>
#>  1 Marc… Whal… F         0       0      0       0       5      0       0       0
#>  2 Marc… Whal… F         0       0      0       2       4      1       0       0
#>  3 Febr… Beau… F         1       0      1       2       5      0       0       0
#>  4 Febr… Beau… F         2       0      2       0       5      1       0       0
#>  5 Febr… Beau… F         0       0      0       0       2      1       0       0
#>  6 Febr… Beau… F         2       1      3       2       5      0       0       0
#>  7 Febr… Beau… F         0       0      0       0       1      0       0       0
#>  8 Febr… Beau… F         0       0      0       2       0      1       0       1
#>  9 Janu… PHF … F         0       0      0       0       0      0       0       0
#> 10 Janu… PHF … F         0       0      0       0       0      0       0       0
#> # … with 52 more rows, 16 more variables: faceoffs_won_lost <chr>,
#> #   faceoffs_won <int>, faceoffs_lost <int>, faceoffs_win_pct <dbl>, PPG <int>,
#> #   SHG <int>, shots <int>, shots_blocked <int>, FoW <int>, FoL <int>,
#> #   player_name <chr>, player_id <dbl>, position <chr>,
#> #   player_image_href <chr>, game_href <chr>, game_id <int>, and abbreviated
#> #   variable names ¹​penalty_minutes, ²​shots_on_goal, ³​giveaways, ⁴​takeaways
#> 
# }