View source: R/espn_cfb_ratings.R
| espn_cfb_qbr | R Documentation |
Get ESPN's Total Quarterback Rating (QBR) and its full set of clutch-weighted EPA components for a college football season.
espn_cfb_qbr(year = NULL, group = 80, athlete_detail = FALSE)
year |
(Integer required): Season, 4 digit format (YYYY). |
group |
(Integer default 80): ESPN group id. |
athlete_detail |
(Logical): when |
Wraps the ESPN core-v2 QBR endpoint
seasons/{year}/types/2/groups/{group}/qbr/0. It returns season-to-date
regular-season QBR for every qualified passer in the requested group
(conference / division). group = 80 is the all-FBS bucket and is the
sensible default; conference group ids (e.g. 4 ACC, 8 Big 12,
12 SEC, 21 Big Ten) also work.
Two parameters ESPN's QBR path technically accepts are deliberately not exposed, because neither carries data for college football:
The .../weeks/{week}/qbr/... path returns the same season aggregate
for every week – use espn_cfb_player_stats() for week-resolved
passing production instead.
The home/away game-location split (.../qbr/1, .../qbr/2) responds
200 but is empty for college football; only the total (.../qbr/0)
is populated.
The result is wide – one row per quarterback – with the headline qbr
column plus the 18 component metrics ESPN derives it from. Players are
returned as ESPN athlete ids only (athlete_id) unless name resolution
is requested.
When athlete_detail = TRUE the human-readable name columns
athlete_display_name, athlete_first_name, athlete_last_name,
athlete_jersey, athlete_position, and athlete_position_abbreviation
are appended. There is no bulk athlete-name catalog, so resolving names
here costs one HTTP call per quarterback – roughly 130 extra
requests for an all-FBS pull. It therefore defaults to FALSE. A
per-athlete fetch failure leaves that quarterback's name columns NA
rather than erroring the wrapper. To resolve names without these extra
calls, join athlete_id to another athlete source (e.g.
cfbd_team_roster()).
A data frame with one row per quarterback:
| col_name | types | description |
| season | integer | Season (4-digit year). |
| season_type | integer | ESPN season type (2 = regular season). |
| group_id | character | ESPN group id queried (80 = all FBS). |
| athlete_id | character | ESPN athlete id (parsed from athlete_ref). |
| team_id | character | ESPN team id (parsed from team_ref). |
| qbpaa | numeric | QB Points Added Above Average. |
| cwepa_passes_condensed | numeric | Clutch-weighted EPA from passes (condensed). |
| cwepa_rushes | numeric | Clutch-weighted EPA from designed rushes. |
| cwepa_sacked_condensed | numeric | Clutch-weighted EPA lost to sacks (condensed). |
| cwepa_penalties | numeric | Clutch-weighted EPA from penalties. |
| cwepa_total | numeric | Total clutch-weighted EPA. |
| action_plays | numeric | Action plays charged to the quarterback. |
| cw_average | numeric | Clutch-weighted average win value per play. |
| qbr | numeric | Total Quarterback Rating (0-100). |
| cwepa_passes | numeric | Clutch-weighted EPA from pass attempts. |
| cwepa_interceptions | numeric | Clutch-weighted EPA lost to interceptions. |
| cwepa_yards_after_carry | numeric | Clutch-weighted EPA from yards after carry. |
| cwepa_runs | numeric | Clutch-weighted EPA from runs. |
| cwepa_scrambles | numeric | Clutch-weighted EPA from scrambles. |
| cwepa_sacked | numeric | Clutch-weighted EPA lost to sacks. |
| cwepa_fumbles | numeric | Clutch-weighted EPA lost to fumbles. |
| avg_opp_dqbr | numeric | Average opponent defensive QBR faced. |
| sched_adj_qbr | numeric | Schedule-adjusted QBR. |
| unqualified_rank | numeric | QBR rank including unqualified passers. |
| athlete_ref | character | $ref URL to the athlete-in-season resource. |
| team_ref | character | $ref URL to the team-in-season resource. |
| athlete_display_name | character | Player display name; athlete_detail = TRUE only. |
| athlete_first_name | character | Player first name; athlete_detail = TRUE only. |
| athlete_last_name | character | Player last name; athlete_detail = TRUE only. |
| athlete_jersey | character | Player jersey number; athlete_detail = TRUE only. |
| athlete_position | character | Player position name; athlete_detail = TRUE only. |
| athlete_position_abbreviation | character | Player position abbreviation; athlete_detail = TRUE only. |
Other ESPN CFB Functions:
espn_cfb_award(),
espn_cfb_awards(),
espn_cfb_clear_cache(),
espn_cfb_coach(),
espn_cfb_coach_record(),
espn_cfb_coaches(),
espn_cfb_franchise(),
espn_cfb_franchises(),
espn_cfb_futures(),
espn_cfb_game_broadcasts(),
espn_cfb_game_drive_plays(),
espn_cfb_game_drives(),
espn_cfb_game_leaders(),
espn_cfb_game_odds(),
espn_cfb_game_pbp(),
espn_cfb_game_play(),
espn_cfb_game_player_box(),
espn_cfb_game_player_statistics(),
espn_cfb_game_powerindex(),
espn_cfb_game_predictor(),
espn_cfb_game_probabilities(),
espn_cfb_game_situation(),
espn_cfb_game_status(),
espn_cfb_game_team_leaders(),
espn_cfb_game_team_linescores(),
espn_cfb_game_team_records(),
espn_cfb_game_team_roster(),
espn_cfb_game_team_statistics(),
espn_cfb_game_teams(),
espn_cfb_groups(),
espn_cfb_pbp_v2(),
espn_cfb_player(),
espn_cfb_player_career_stats(),
espn_cfb_player_eventlog(),
espn_cfb_player_gamelog(),
espn_cfb_player_overview(),
espn_cfb_player_seasons(),
espn_cfb_player_splits(),
espn_cfb_player_stats_v3(),
espn_cfb_players(),
espn_cfb_position(),
espn_cfb_positions(),
espn_cfb_powerindex(),
espn_cfb_rankings(),
espn_cfb_recruits(),
espn_cfb_season_info(),
espn_cfb_season_types(),
espn_cfb_season_weeks(),
espn_cfb_seasons(),
espn_cfb_standings(),
espn_cfb_team(),
espn_cfb_team_ats(),
espn_cfb_team_awards(),
espn_cfb_team_coaches(),
espn_cfb_team_events(),
espn_cfb_team_leaders(),
espn_cfb_team_powerindex(),
espn_cfb_team_ranks(),
espn_cfb_team_record(),
espn_cfb_team_roster(),
espn_cfb_team_schedule(),
espn_cfb_teams(),
espn_cfb_unnest_plays(),
espn_cfb_venue(),
espn_cfb_venues(),
espn_cfb_week_rankings()
try(espn_cfb_qbr(year = 2024))
try(espn_cfb_qbr(year = 2024, athlete_detail = TRUE))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.