Skip to contents

This function retrieves information about all releases attached to a given repository.

Usage

pb_releases(
  repo = guess_repo(),
  .token = gh::gh_token(),
  verbose = getOption("piggyback.verbose", default = TRUE)
)

Arguments

repo

GitHub repository specification in the form of "owner/repo", if not specified will try to guess repo based on current working directory.

.token

a GitHub API token, defaults to gh::gh_token()

verbose

defaults to TRUE, use FALSE to silence messages

Value

a dataframe of all releases available within a repository.

Examples

# \donttest{
try({ # wrapped in try block to prevent CRAN errors
 pb_releases("nflverse/nflverse-data")
})
#>         release_name release_id
#> 1     weekly_rosters   73313637
#> 2            players   69785162
#> 3  pbp_participation   71636554
#> 4          officials   69773595
#> 5               misc   69471165
#> 6               test   66262662
#> 7        draft_picks   66254658
#> 8          contracts   65273753
#> 9        snap_counts   58153010
#> 10           rosters   58152863
#> 11      player_stats   58152881
#> 12      pfr_advstats   58152981
#> 13               pbp   58152862
#> 14     nextgen_stats   58152931
#> 15          injuries   58152949
#> 16      depth_charts   58152948
#> 17           combine   60901499
#>                                                                                                                                                                                            release_body
#> 1                                                                                                                                       Week-level rosters via NFL Shield v2 API, dating back to 2002. 
#> 2                                                                                                Player information for nflverse. This should be the go-to for position and ID mappings going forward. 
#> 3                                                                                                                                                                 Participation data for plays from NGS
#> 4                                                                                                                             Data about which referees and officials were assigned to specific games. 
#> 5  Various bits of data stored here as onetime jobs. Not automatically updated. Please file an issue or mention it on discord if you'd like to request something be maintained on an automatic schedule
#> 6                                                                                                                                                                                  for internal testing
#> 7                                                         Draft picks dating back to 1980, courtesy of Pro Football Reference. \r\n\r\nIncludes some career-level and ApproxValue/HOF/MVP/PB stats.\r\n
#> 8                                                                                                                                 OverTheCap contract data, accessed with `nflreadr::load_contracts()`.
#> 9                                                                                                       Snap counts data, accessed with `nflreadr::load_snap_counts()`.\r\n\r\nLast Updated: 2022-03-06
#> 10                                                                                                                                                Roster data, accessed with `nflreadr::load_rosters()`
#> 11                                                                                                                                     Play by play data, accessed with `nflreadr::load_player_stats()`
#> 12                                                                                                                        PFR Adv Stats data, accessed with `nflreadr::load_pfr_advstats()`\r\n\r\n\r\n
#> 13                                                                                                                                              Play by play data, accessed with `nflreadr::load_pbp()`
#> 14                                                                                                                              NFL Next Gen Stats data, accessed with `nflreadr::load_nextgen_stats()`
#> 15                                                                                                                                             Injuries data, accessed with `nflreadr::load_injuries()`
#> 16                                                                                                                                      Depth chart data, accessed with `nflreadr::load_depth_charts()`
#> 17                                                                                NFL Combine Data courtesy of PFR, accessed with `nflreadr::load_combine()`. \r\n\r\nLast Updated: 2022-03-05 17:06:33
#>             tag_name draft           created_at         published_at
#> 1     weekly_rosters FALSE 2022-06-15T16:58:26Z 2022-08-01T07:45:30Z
#> 2            players FALSE 2022-06-15T16:58:26Z 2022-06-19T05:36:22Z
#> 3  pbp_participation FALSE 2022-06-15T16:58:26Z 2022-07-10T04:32:49Z
#> 4          officials FALSE 2022-06-15T16:58:26Z 2022-06-18T17:47:11Z
#> 5               misc FALSE 2022-05-29T16:57:43Z 2022-06-14T23:46:04Z
#> 6               test FALSE 2022-05-06T19:04:21Z 2022-05-06T19:56:46Z
#> 7        draft_picks FALSE 2022-05-06T18:12:18Z 2022-05-06T18:15:12Z
#> 8          contracts FALSE 2022-03-21T14:03:51Z 2022-04-25T19:40:32Z
#> 9        snap_counts FALSE 2022-01-28T02:09:45Z 2022-01-28T02:15:02Z
#> 10           rosters FALSE 2022-01-28T02:09:45Z 2022-01-28T02:12:10Z
#> 11      player_stats FALSE 2022-01-28T02:09:45Z 2022-01-28T02:12:36Z
#> 12      pfr_advstats FALSE 2022-01-28T02:09:45Z 2022-01-28T02:14:24Z
#> 13               pbp FALSE 2022-01-28T02:09:45Z 2022-01-28T02:12:09Z
#> 14     nextgen_stats FALSE 2022-01-28T02:09:45Z 2022-01-28T02:13:25Z
#> 15          injuries FALSE 2022-01-28T02:09:45Z 2022-01-28T02:13:49Z
#> 16      depth_charts FALSE 2022-01-28T02:09:45Z 2022-01-28T02:13:47Z
#> 17           combine FALSE 2022-01-28T02:09:45Z 2022-03-03T15:51:29Z
#>                                                                    html_url
#> 1     https://github.com/nflverse/nflverse-data/releases/tag/weekly_rosters
#> 2            https://github.com/nflverse/nflverse-data/releases/tag/players
#> 3  https://github.com/nflverse/nflverse-data/releases/tag/pbp_participation
#> 4          https://github.com/nflverse/nflverse-data/releases/tag/officials
#> 5               https://github.com/nflverse/nflverse-data/releases/tag/misc
#> 6               https://github.com/nflverse/nflverse-data/releases/tag/test
#> 7        https://github.com/nflverse/nflverse-data/releases/tag/draft_picks
#> 8          https://github.com/nflverse/nflverse-data/releases/tag/contracts
#> 9        https://github.com/nflverse/nflverse-data/releases/tag/snap_counts
#> 10           https://github.com/nflverse/nflverse-data/releases/tag/rosters
#> 11      https://github.com/nflverse/nflverse-data/releases/tag/player_stats
#> 12      https://github.com/nflverse/nflverse-data/releases/tag/pfr_advstats
#> 13               https://github.com/nflverse/nflverse-data/releases/tag/pbp
#> 14     https://github.com/nflverse/nflverse-data/releases/tag/nextgen_stats
#> 15          https://github.com/nflverse/nflverse-data/releases/tag/injuries
#> 16      https://github.com/nflverse/nflverse-data/releases/tag/depth_charts
#> 17           https://github.com/nflverse/nflverse-data/releases/tag/combine
#>                                                                                       upload_url
#> 1  https://uploads.github.com/repos/nflverse/nflverse-data/releases/73313637/assets{?name,label}
#> 2  https://uploads.github.com/repos/nflverse/nflverse-data/releases/69785162/assets{?name,label}
#> 3  https://uploads.github.com/repos/nflverse/nflverse-data/releases/71636554/assets{?name,label}
#> 4  https://uploads.github.com/repos/nflverse/nflverse-data/releases/69773595/assets{?name,label}
#> 5  https://uploads.github.com/repos/nflverse/nflverse-data/releases/69471165/assets{?name,label}
#> 6  https://uploads.github.com/repos/nflverse/nflverse-data/releases/66262662/assets{?name,label}
#> 7  https://uploads.github.com/repos/nflverse/nflverse-data/releases/66254658/assets{?name,label}
#> 8  https://uploads.github.com/repos/nflverse/nflverse-data/releases/65273753/assets{?name,label}
#> 9  https://uploads.github.com/repos/nflverse/nflverse-data/releases/58153010/assets{?name,label}
#> 10 https://uploads.github.com/repos/nflverse/nflverse-data/releases/58152863/assets{?name,label}
#> 11 https://uploads.github.com/repos/nflverse/nflverse-data/releases/58152881/assets{?name,label}
#> 12 https://uploads.github.com/repos/nflverse/nflverse-data/releases/58152981/assets{?name,label}
#> 13 https://uploads.github.com/repos/nflverse/nflverse-data/releases/58152862/assets{?name,label}
#> 14 https://uploads.github.com/repos/nflverse/nflverse-data/releases/58152931/assets{?name,label}
#> 15 https://uploads.github.com/repos/nflverse/nflverse-data/releases/58152949/assets{?name,label}
#> 16 https://uploads.github.com/repos/nflverse/nflverse-data/releases/58152948/assets{?name,label}
#> 17 https://uploads.github.com/repos/nflverse/nflverse-data/releases/60901499/assets{?name,label}
#>    n_assets
#> 1        86
#> 2         6
#> 3        30
#> 4         6
#> 5        10
#> 6         2
#> 7         6
#> 8         7
#> 9        47
#> 10      414
#> 11      251
#> 12       98
#> 13      145
#> 14       77
#> 15       58
#> 16       90
#> 17        6
# }