update_wnba_stats_db() writes one or more WNBA Stats API
datasets into a database. Mirrors the WNBA / WBB update_*_db() shape
but points at the load_wnba_stats_* family. Each dataset is written
to its own table, named wnba_stats_<dataset>.
update_wnba_stats_db(
dbdir = ".",
dbname = "wehoop_db",
datasets = NULL,
seasons = TRUE,
db_connection = NULL
)Invisibly returns TRUE on success.
Directory in which the database is or shall be located.
File name of an existing or desired SQLite database within
dbdir.
Character vector of dataset shortnames (see Details).
Optional integer vector of seasons to load. Defaults to all
available seasons (seasons = TRUE).
A DBIConnection object. When supplied, dbdir and
dbname are ignored.
Unlike update_wnba_db() / update_wbb_db(), there is no historical
"play-by-play table" default to preserve, so datasets is required.
Valid datasets values:
"schedule", "player_game_logs", "pbp", "rosters", "coaches",
"player_stats", "lineups", "team_stats", "standings",
"draft", "shots", "game_rosters", "officials", "possessions".