Learn R Programming

baseballr (version 1.6.0)

sptrc_team_active_payroll: Scrape Team Active Payroll Breakdown from Spotrac

Description

This function allows you to scrape a team's active payroll from Spotrac.

Usage

sptrc_team_active_payroll(team_abbr, year = most_recent_mlb_season())

Value

A data frame of contract data.

col_nametypes
yearnumeric
teamcharacter
player_namecharacter
roster_statuscharacter
agenumeric
posnumeric
statusnumeric
waiver_optionsnumeric
base_salarynumeric
signing_bonusnumeric
payroll_salarynumeric
adj_salarynumeric
payroll_percentnumeric
lux_tax_salarynumeric
total_salarynumeric

Arguments

team_abbr

Team abbreviation

year

Year to load

Examples

Run this code
# \donttest{
 try(sptrc_team_active_payroll(team_abbr = "BAL", year = most_recent_mlb_season()))
# }

Run the code above in your browser using DataLab