tests/testthat/helpers.R

load_test_games <- function(){
  g <- nflreadr::load_schedules(2014:2019)

  if (!nrow(g) > 0) return(tibble::tibble())

  g |>
    dplyr::select(sim = season, game_type, week, away_team, home_team, result)
}

Try the nflseedR package in your browser

Any scripts or data that you put into this service are public.

nflseedR documentation built on April 4, 2025, 2:08 a.m.