View source: R/load_wnba_stats.R
| load_wnba_stats_rosters | R Documentation |
Loads season-level WNBA team rosters scraped from the WNBA
Stats API. One row per athlete-team-season triple. Backed by the
wehoop-wnba-stats-data pipeline that reads raw JSONs from
wehoop-wnba-stats-raw and publishes parquet/rds artifacts to the
wnba_stats_rosters release tag.
Loads season-level WNBA coaching staff data scraped from the
WNBA Stats API. One row per coach-team-season triple. Backed by the
wehoop-wnba-stats-data pipeline that reads raw JSONs from
wehoop-wnba-stats-raw and publishes parquet/rds artifacts to the
wnba_stats_coaches release tag.
Loads season-level WNBA
player statistics. Deprecated: the
wnba_stats_player_season_stats
release tag (R-scraped, Base/Advanced/Misc/Scoring/Usage/
Defense measures) is superseded by the wnba_stats_leaguedash tag
(Python-scraped parameter cube, same 6 measure types plus player_bio
and a wide player_master mega). This function reshapes the cube back
into the old stacked-by-measure_type contract for compatibility; call
the cube's player_stats_* / player_master assets directly with
load_wnba_stats_leaguedash() for the full surface.
Loads season-level WNBA
5-man lineup statistics (
leaguedashlineups-style outputs).
Deprecated: the wnba_stats_lineups release tag (R-scraped,
Base/Advanced measures, 5-man only) is superseded by the
wnba_stats_leaguedash tag (Python-scraped parameter cube: 6 measure
types x 2/3/4/5-man). This function reshapes the cube back into the old
5-man Base+Advanced contract for compatibility; call the cube's
lineups_* / lineups_master assets directly with
load_wnba_stats_leaguedash() for the full surface.
Loads season-level team
statistics (
leaguedashteamstats-style outputs). Deprecated: the
wnba_stats_team_season_stats release tag (R-scraped, Base/
Advanced/Misc/Scoring/Defense/Opponent measures) is superseded
by the wnba_stats_leaguedash tag (Python-scraped parameter cube, same
6 measures plus Four Factors and a wide team_master mega). This
function reshapes the cube back into the old stacked-by-measure_type
contract for compatibility; call the cube's team_stats_* /
team_master assets directly with
load_wnba_stats_leaguedash() for the full surface.
Loads season-level WNBA
standings (
leaguestandingsv3-style outputs). One row per team-season.
Deprecated: the wnba_stats_standings release tag (R-scraped) is
superseded by the wnba_stats_leaguedash tag's standings asset
(same underlying endpoint/params, Python-scraped) — this is close to a
pure passthrough.
Loads season-level WNBA draft picks scraped from the WNBA
Stats API (drafthistory-style outputs). One row per pick. Backed by
the wehoop-wnba-stats-data pipeline that reads raw JSONs from
wehoop-wnba-stats-raw and publishes parquet/rds artifacts to the
wnba_stats_draft release tag.
Loads shot events scraped from the WNBA Stats API. One row
per shot attempt with legacy court coordinates, action/sub type,
distance, and made/missed result, carried through from the V3
play-by-play feed (not shotchartdetail). Backed by the
wehoop-wnba-stats-data pipeline that reads raw JSONs from
wehoop-wnba-stats-raw and publishes parquet/rds artifacts to the
wnba_stats_shots release tag.
Loads the per-game inactive player list scraped from the
WNBA Stats API – the InactivePlayers result set of
boxscoresummaryv2. One row per inactive athlete-game pair, not a full
per-game roster: use load_wnba_stats_player_game_logs() for the
athletes who did play. Backed by the wehoop-wnba-stats-data pipeline
that reads raw JSONs from wehoop-wnba-stats-raw and publishes
parquet/rds artifacts to the wnba_stats_game_rosters release tag.
Coverage is thin by construction because the upstream result set is thin: stats.wnba.com reports inactives for only a fraction of games, and most heavily for 2006-2008 and 2021 onward. Season row counts range from 1 (1997) to 610 across 184 games (2026); 2009-2012 carry fewer than 10 rows each. A season with almost no rows is upstream sparsity, not a download failure.
Loads game-level officials data scraped from the WNBA Stats
API (boxscoresummaryv2-style outputs). One row per official-game pair.
Backed by the wehoop-wnba-stats-data pipeline that reads raw JSONs
from wehoop-wnba-stats-raw and publishes parquet/rds artifacts to the
wnba_stats_officials release tag.
Loads per-player per-game logs scraped from
stats.wnba.com/leaguegamelog?PlayerOrTeam=P (one row per
athlete-game pair: minutes, shooting splits, rebounds, steals, blocks,
turnovers, personal fouls, plus/minus). Backed by the
wehoop-wnba-stats-data pipeline that publishes parquet/rds artifacts
to the wnba_stats_player_game_logs release tag.
Loads season-level WNBA schedules scraped from
stats.wnba.com/leaguegamefinder (regular season + playoffs combined,
pre-rejoined home/away). Backed by the wehoop-wnba-stats-data
pipeline that publishes parquet/rds artifacts to the
wnba_stats_schedules release tag.
Loads season-level WNBA play-by-play (V3), supplied by
wnba_pbp() in the upstream compile script. Backed by the
wehoop-wnba-stats-data pipeline that publishes parquet/rds artifacts to
the wnba_stats_pbp release tag.
load_wnba_stats_rosters_manifest() returns the per-season
manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats rosters release tag without
downloading any season's full data.
load_wnba_stats_coaches_manifest() returns the per-season
manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats coaches release tag without
downloading any season's full data.
load_wnba_stats_player_stats_manifest() returns the
per-season manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats player season stats release tag
without downloading any season's full data.
load_wnba_stats_lineups_manifest() returns the per-season
manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats lineups release tag without
downloading any season's full data.
load_wnba_stats_team_stats_manifest() returns the per-season
manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats team season stats release tag
without downloading any season's full data.
load_wnba_stats_standings_manifest() returns the per-season
manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats standings release tag without
downloading any season's full data.
load_wnba_stats_draft_manifest() returns the per-season
manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats draft release tag without
downloading any season's full data.
load_wnba_stats_shots_manifest() returns the per-season
manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats shots release tag without
downloading any season's full data.
load_wnba_stats_game_rosters_manifest() returns the
per-season manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats game rosters release tag without
downloading any season's full data.
load_wnba_stats_officials_manifest() returns the per-season
manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats officials release tag without
downloading any season's full data.
load_wnba_stats_player_game_logs_manifest() returns the
per-season manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats player game logs release tag
without downloading any season's full data.
load_wnba_stats_schedule_manifest() returns the per-season
manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats schedules release tag without
downloading any season's full data.
load_wnba_stats_pbp_manifest() returns the per-season
manifest CSV (season, row_count, generated_at_utc,
source_endpoint) for the WNBA Stats play-by-play release tag without
downloading any season's full data.
Loads possession-level data derived from the WNBA Stats API
play-by-play – one row per possession, with the on-court 5-man lineups
for both teams, shooting/rebounding/turnover splits, and the possession
start type. Backed by the wehoop-wnba-stats-data pipeline that reads
raw JSONs from wehoop-wnba-stats-raw and publishes csv.gz/parquet/rds
artifacts to the wnba_stats_possessions release tag.
load_wnba_stats_rosters(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_coaches(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_player_stats(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_lineups(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_team_stats(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_standings(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_draft(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_shots(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_game_rosters(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_officials(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_player_game_logs(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_schedule(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_pbp(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
load_wnba_stats_rosters_manifest()
load_wnba_stats_coaches_manifest()
load_wnba_stats_player_stats_manifest()
load_wnba_stats_lineups_manifest()
load_wnba_stats_team_stats_manifest()
load_wnba_stats_standings_manifest()
load_wnba_stats_draft_manifest()
load_wnba_stats_shots_manifest()
load_wnba_stats_game_rosters_manifest()
load_wnba_stats_officials_manifest()
load_wnba_stats_player_game_logs_manifest()
load_wnba_stats_schedule_manifest()
load_wnba_stats_pbp_manifest()
load_wnba_stats_possessions(
seasons = most_recent_wnba_stats_season(),
...,
dbConnection = NULL,
tablename = NULL
)
seasons |
A vector of 4-digit years associated with given WNBA
seasons. Published coverage runs 1997 through the most recent season,
with no gaps. Pass |
... |
Additional arguments passed to an underlying function that writes the season data into a database. |
dbConnection |
A |
tablename |
The name of the data table within the database |
Returns a wehoop_data tibble with one row per athlete-team-season.
Returns a wehoop_data tibble with one row per coach-team-season.
Returns a wehoop_data tibble of player season stats.
Returns a wehoop_data tibble of lineup stats.
Returns a wehoop_data tibble of team season stats.
| col_name | types | description |
| season | integer | Season identifier (4-digit year or 'YYYY-YY' string). |
| season_type | character | Season type (1=pre-season, 2=regular season, 3=postseason, 4=off-season for ESPN; or string label for WNBA Stats). |
| team_id | character | Unique team identifier. |
| team_name | character | Full team display name (e.g. 'Las Vegas Aces'). |
| team_abbreviation | character | Short team abbreviation (e.g. 'LAS'). |
| gp | integer | Games played. |
| w | integer | Wins. |
| l | integer | Losses. |
| w_pct | numeric | Wins percentage (0-1 decimal). |
| min | numeric | Minutes played. |
| fgm | numeric | Field goals made. |
| fga | numeric | Field goal attempts. |
| fg_pct | numeric | Field goal percentage (0-1). |
| fg3m | numeric | Three-point field goals made. |
| fg3a | numeric | Three-point field goal attempts. |
| fg3_pct | numeric | Three-point field goal percentage (0-1). |
| ftm | numeric | Free throws made. |
| fta | numeric | Free throw attempts. |
| ft_pct | numeric | Free throw percentage (0-1). |
| oreb | numeric | Offensive rebounds. |
| dreb | numeric | Defensive rebounds. |
| reb | numeric | Total rebounds. |
| ast | numeric | Assists. |
| tov | numeric | Turnovers. |
| stl | numeric | Steals. |
| blk | numeric | Blocks. |
| pf | numeric | Personal fouls. |
| pts | numeric | Points scored. |
| plus_minus | numeric | Plus/minus point differential while on court. |
Returns a wehoop_data tibble of team standings.
| col_name | types | description |
| season | integer | Season identifier (4-digit year or 'YYYY-YY' string). |
| season_id | character | Unique season identifier. |
| team_id | character | Unique team identifier. |
| team_city | character | Team city or region (e.g. 'Las Vegas'). |
| team_name | character | Full team display name (e.g. 'Las Vegas Aces'). |
| conference | character | Filter players or teams by conference. |
| conference_record | character | Conference win-loss record. |
| playoff_rank | integer | League/season rank for playoff. |
| wins | integer | Total wins. |
| losses | integer | Total losses. |
| win_pct | numeric | Win percentage (0-1 decimal). |
| home_record | character | Home win-loss record. |
| road_record | character | Win-loss record for road. |
| l10 | character | L10. |
| strcurrentstreak | character | Strcurrentstreak. |
| points_pg | numeric | Points pg. |
| opp_points_pg | numeric | Opponent points pg. |
| diff_points_pg | numeric | Diff points pg. |
Returns a wehoop_data tibble of WNBA draft picks.
| col_name | types | description |
| person_id | integer | Unique player identifier (V3 endpoints). |
| player_name | character | Player name. |
| season | integer | Season identifier (4-digit year). |
| round_number | integer | Numeric round. |
| round_pick | integer | Round pick. |
| overall_pick | integer | Overall pick. |
| draft_type | character | Draft type ('Draft', 'Allocation' or 'Elite'). |
| team_id | integer | Unique team identifier. |
| team_city | character | Team city or region (e.g. 'Las Vegas'). |
| team_name | character | Full team display name (e.g. 'Las Vegas Aces'). |
| team_abbreviation | character | Short team abbreviation (e.g. 'LAS'). |
| organization | character | Organization. |
| organization_type | character | Organization type. |
| player_profile_flag | integer | Player profile flag. |
Returns a wehoop_data tibble with one row per shot attempt.
| col_name | types | description |
| game_id | character | Unique game identifier. |
| season | integer | Season identifier (4-digit year). |
| period | integer | Period of the game (1-4 quarters; 5+ for OT). |
| clock | character | Game clock remaining in the period (ISO 8601 duration). |
| team_id | integer | Unique team identifier for the shooting team. |
| team_tricode | character | Three-letter team code (e.g. 'LAS' / 'NYL'). |
| person_id | integer | Unique player identifier for the shooter. |
| player_name | character | Shooter's name. |
| action_type | character | Action type label ('Made Shot' or 'Missed Shot'). |
| sub_type | character | Shot sub type (e.g. 'Jump Shot', 'Layup', 'DUNK'). |
| shot_result | character | Shot result, 'Made' or 'Missed'. |
| shot_value | integer | Points the shot was worth (2 or 3). |
| shot_distance | integer | Shot distance from the basket, in feet. |
| x_legacy | integer | Legacy X coordinate on the court (0 = basket center). |
| y_legacy | integer | Legacy Y coordinate on the court (baseline at 0). |
| description | character | Text description of the play. |
| score_home | character | Home team score after the play. |
| score_away | character | Away team score after the play. |
Returns a wehoop_data tibble with one row per inactive
athlete-game pair.
| col_name | types | description |
| player_id | integer | Unique player identifier. |
| first_name | character | Player's first name. |
| last_name | character | Player's last name. |
| jersey_num | character | Jersey number worn by the player. |
| team_id | integer | Unique team identifier. |
| team_city | character | Team city or region (e.g. 'Las Vegas'). |
| team_name | character | Full team display name (e.g. 'Las Vegas Aces'). |
| team_abbreviation | character | Short team abbreviation (e.g. 'LAS'). |
| season | integer | Season identifier (4-digit year). |
| game_id | character | Unique game identifier. |
Returns a wehoop_data tibble with one row per official-game pair.
| col_name | types | description |
| official_id | integer | Unique official / referee identifier. |
| first_name | character | Official's first name. |
| last_name | character | Official's last name. |
| jersey_num | character | Jersey number worn by the official. |
| season | integer | Season identifier (4-digit year). |
| game_id | character | Unique game identifier. |
Returns a wehoop_data tibble of per-athlete per-game log rows.
Returns a wehoop_data tibble of per-season schedules, one row per
game with the home/away sides pre-joined into home_* / away_* columns.
| col_name | types | description |
| game_id | character | Unique game identifier. |
| season | integer | Season identifier (4-digit year). |
| season_type | character | Portion of the season: regular-season or playoffs. |
| game_date | character | Date the game was played, as an ISO YYYY-MM-DD string. |
| matchup | character | Matchup string, home side first (e.g. WAS vs. NYL). |
| home_team_id | integer | Unique WNBA Stats team identifier for the home team. |
| home_team_abbreviation | character | Home team abbreviation. |
| home_team_name | character | Home team full name. |
| home_pts | integer | Points scored by the home team. |
| home_wl | character | Home team result, W or L. |
| away_team_id | integer | Unique WNBA Stats team identifier for the away team. |
| away_team_abbreviation | character | Away team abbreviation. |
| away_team_name | character | Away team full name. |
| away_pts | integer | Points scored by the away team. |
| away_wl | character | Away team result, W or L. |
Returns a wehoop_data tibble of per-event play-by-play rows.
Returns a wehoop_data tibble with one row per possession.
| col_name | types | description |
| game_id | character | Unique game identifier. |
| period | integer | Period of the game (1-2 halves pre-2016, 1-4 quarters 2016+). |
| possession_number | integer | Sequential possession number within the game. |
| offense_team_id | integer | Team identifier for the team on offense. |
| defense_team_id | integer | Team identifier for the team on defense. |
| start_order_index | integer | Play-by-play order index at the start of the possession. |
| end_order_index | integer | Play-by-play order index at the end of the possession. |
| start_seconds_remaining | numeric | Seconds remaining in the period at possession start. |
| end_seconds_remaining | numeric | Seconds remaining in the period at possession end. |
| points | integer | Points scored on the possession. |
| is_second_chance | logical | Whether the possession followed an offensive rebound. |
| number_in_period | integer | Sequential possession number within the period. |
| possession_start_type | character | How the possession started (e.g. 'OffDeadball', 'OffRebound'). |
| count_as_possession | logical | Whether the event counts as a scoreable possession. |
| fg2a | integer | 2-point field goal attempts by the lineup. |
| fg2m | integer | 2-point field goals made by the lineup. |
| fg3a | integer | Fg3a. |
| fg3m | integer | Fg3m. |
| fta | integer | Free throw attempts by the lineup. |
| ftm | integer | Free throws made by the lineup. |
| oreb | integer | Offensive rebounds. |
| dreb | integer | Defensive rebounds. |
| tov | integer | Turnovers. |
| off_player_1 | integer | Offensive lineup slot 1 player identifier. |
| off_player_2 | integer | Offensive lineup slot 2 player identifier. |
| off_player_3 | integer | Offensive lineup slot 3 player identifier. |
| off_player_4 | integer | Offensive lineup slot 4 player identifier. |
| off_player_5 | integer | Offensive lineup slot 5 player identifier. |
| def_player_1 | integer | Defensive lineup slot 1 player identifier. |
| def_player_2 | integer | Defensive lineup slot 2 player identifier. |
| def_player_3 | integer | Defensive lineup slot 3 player identifier. |
| def_player_4 | integer | Defensive lineup slot 4 player identifier. |
| def_player_5 | integer | Defensive lineup slot 5 player identifier. |
| season | integer | Season identifier (4-digit year). |
Saiem Gilani
Other WNBA Stats loader functions:
load_wnba_stats_leaguedash()
try(load_wnba_stats_rosters(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_coaches(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_player_stats(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_lineups(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_team_stats(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_standings(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_draft(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_shots(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_game_rosters(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_officials(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_player_game_logs(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_schedule(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_pbp(seasons = most_recent_wnba_stats_season()))
try(load_wnba_stats_possessions(seasons = most_recent_wnba_stats_season()))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.