Skip to contents

Returns the NHL Edge skating-distance detail payload for a single team. Wraps https://api-web.nhle.com/v1/edge/team-skating-distance-detail/{teamId}/.... When season is NULL (default) the /now endpoint is used to fetch the current season.

Usage

nhl_edge_team_skating_distance_detail(team_id, season = NULL, game_type = 2)

Arguments

team_id

Integer NHL team ID (e.g., 10 for Toronto Maple Leafs).

season

Optional 4-digit end-year (e.g., 2025 for the 2024-25 season), an 8-character API season (e.g., "20242025"), or NULL (default) for the current season via the /now endpoint.

game_type

Integer game type. 1 = preseason, 2 = regular season (default), 3 = playoffs.

Value

A data frame (fastRhockey_data) with the following columns:

col_nametypesdescription
game_center_linkcharacterLink to the NHL game center page for the game.
game_datecharacterGame date.
is_home_teamlogicalWhether the team was the home team.
toi_allintegerTime on ice (all situations), in seconds.
toi_evenintegerTime on ice (even strength), in seconds.
toi_ppintegerTime on ice (power play), in seconds.
toi_pkintegerTime on ice (penalty kill), in seconds.
distance_skated_all_imperialnumericDistance skated (all situations), in miles.
distance_skated_all_metricnumericDistance skated (all situations), in kilometers.
distance_skated_even_imperialnumericDistance skated (even strength), in miles.
distance_skated_even_metricnumericDistance skated (even strength), in kilometers.
distance_skated_pp_imperialnumericDistance skated (power play), in miles.
distance_skated_pp_metricnumericDistance skated (power play), in kilometers.
distance_skated_pk_imperialnumericDistance skated (penalty kill), in miles.
distance_skated_pk_metricnumericDistance skated (penalty kill), in kilometers.
home_team_common_name_defaultcharacterHome team common name (default language).
home_team_common_name_frcharacterHome team common name (French).
home_team_place_name_with_preposition_defaultcharacterHome team place name with preposition (default).
home_team_place_name_with_preposition_frcharacterHome team place name with preposition (French).
home_team_team_logo_lightcharacterURL to the home team light logo.
home_team_team_logo_darkcharacterURL to the home team dark logo.
away_team_common_name_defaultcharacterAway team common name (default language).
away_team_place_name_with_preposition_defaultcharacterAway team place name with preposition (default).
away_team_place_name_with_preposition_frcharacterAway team place name with preposition (French).
away_team_team_logo_lightcharacterURL to the away team light logo.
away_team_team_logo_darkcharacterURL to the away team dark logo.

Examples

# \donttest{
  try(nhl_edge_team_skating_distance_detail(team_id = 10))
#> ── NHL Edge Team Skating Distance Detail ────────────────── fastRhockey 1.1.0 ──
#> ℹ Data updated: 2026-11-02 03:50:59 UTC
#> # A tibble: 10 × 25
#>    game_center_link        game_date is_home_team toi_all toi_even toi_pp toi_pk
#>    <chr>                   <chr>     <lgl>          <int>    <int>  <int>  <int>
#>  1 /gamecenter/tor-vs-van… 2026-10-… FALSE          17612    15200    860   1552
#>  2 /gamecenter/tor-vs-sea… 2026-10-… FALSE          17489    14935    730   1824
#>  3 /gamecenter/tor-vs-cgy… 2026-10-… FALSE          17422    14130   1200   2092
#>  4 /gamecenter/tor-vs-edm… 2026-10-… FALSE          17497    16375     70   1052
#>  5 /gamecenter/nyr-vs-tor… 2026-10-… TRUE           17912    16467    965    480
#>  6 /gamecenter/tor-vs-cbj… 2026-10-… FALSE          17280    12971   1990   2319
#>  7 /gamecenter/sjs-vs-tor… 2026-10-… TRUE           17400    13560   1920   1920
#>  8 /gamecenter/nyi-vs-tor… 2026-10-… TRUE           17802    15092   1800    910
#>  9 /gamecenter/buf-vs-tor… 2026-10-… TRUE           18342    16838    920    584
#> 10 /gamecenter/tor-vs-uta… 2026-10-… FALSE          17674    14558   1776   1340
#> # ℹ 18 more variables: distance_skated_all_imperial <dbl>,
#> #   distance_skated_all_metric <dbl>, distance_skated_even_imperial <dbl>,
#> #   distance_skated_even_metric <dbl>, distance_skated_pp_imperial <dbl>,
#> #   distance_skated_pp_metric <dbl>, distance_skated_pk_imperial <dbl>,
#> #   distance_skated_pk_metric <dbl>, home_team_common_name_default <chr>,
#> #   home_team_place_name_with_preposition_default <chr>,
#> #   home_team_place_name_with_preposition_fr <chr>, …
# }