ds.compile_games: Compile Games

Description Usage Arguments Details Value

View source: R/1_compile.R

Description

compile_games() collects, parses and compiles all game data corresponding to a given vector of game IDs and season

Usage

1
2
3
ds.compile_games(games = ds.all_games, season = "20182019",
  pause = 1, try_tolerance = 3, agents = ds.user_agents[[1]],
  presave = TRUE, use_presaved = TRUE, data_dir = "nhlgamedata")

Arguments

games

numeric vector. The game IDs. Defaults to all regular-season and playoff game IDs.

season

character. The season. Default "20182019".

pause

numeric. Seconds to pause between games. Default 1.

try_tolerance

numeric. Number of times to bang head against wall. Default 3.

agents

character vector. HTTP user agent strings. Defaults to a single sensible string.

presave

logical. Save scraped games for later retrieval? Default TRUE.

use_presaved

logical. Reload any presaved games instead of downloading? Default TRUE.

data_dir

character. Path to saved games. Default "nhlgamedata".

Details

This is the principal function you should find yourself calling.

Value

A list object containing c([[1]] = PBP, [[2]] = Roster, [[3]] = Shifts)


deepfriar/dryscrape documentation built on Nov. 5, 2019, 2:27 p.m.