Learn R Programming

nbastatR (version 0.1.110202031)

get_teams_hoopshype_salaries: Hoopshype teams players salaries

Description

Detailed salaries for each player and team from hoopshype

Usage

get_teams_hoopshype_salaries(teams = NULL, all_teams = TRUE,
  assume_player_opt_out = T, assume_team_doesnt_exercise = T,
  nest_data = F, return_message = TRUE)

Arguments

teams

vector of team names

all_teams

if TRUE returns all teams

assume_player_opt_out

if TRUE assumes player opt out of options

assume_team_doesnt_exercise

if TRUE assumes teams don't excerise options

nest_data

if TRUE nests data

return_message

if TRUE returns a message

Value

a `data_frame`

See Also

Other hoopshype: get_hoops_hype_teams_salary_summary

Other salaries: get_all_nba_teams_salaries, get_hoops_hype_teams_salary_summary, get_nba_team_salaries

Examples

Run this code
# NOT RUN {
library(dplyr)
df_salaries <-
get_teams_hoopshype_salaries(all_teams = TRUE,
 nest_data = F, return_message = T)
 ## By Expiring Salary Type and Team
 df_salaries %>% group_by(slugSeason,  nameTeam, isFinalSeason) %>%
 summarise(expiringSalaries = sum(amountContractMil, na.rm = T) / 1000000) %>%
 arrange(nameTeam)
# }

Run the code above in your browser using DataLab