View source: R/do_possession_stats_lineup.R
| do_possession_stats_lineup | R Documentation |
Compute the possessions-related statistics for lineups. These statistics are offensive rating, defensive rating, net rating, pace and number of possessions.
do_possession_stats_lineup(data_combs, team_name, type_lineup, type_period, type_opponent,
cols_group = c("team", "lineup"))
data_combs |
Data frame with all the combinations of lineups. |
team_name |
Name of the team. |
type_lineup |
Type of lineups to analyze. Options are 'quintet', 'quartet', 'trio', 'duo' and 'single'. |
type_period |
Period of interest. Options are xC, where x starts from 1. Common periods are from 1 to 4. Overtimes are labeled with the next numbers, such as 5C for the first overtime and 6C for the second one. Nothing to do if NULL. |
type_opponent |
Name of the opponent teams. Nothing to do if NULL. |
cols_group |
Group of columns to apply the computations. Default is c("team", "lineup") to compute the metrics just for the players on court. To compute them for the players both on and off court, use c("team", "lineup", "status"). |
See https://www.basketball-reference.com/about/glossary.html for formulas and explanations.
A data frame with the possessions statistics for each lineup.
Guillermo Vinue
do_possession_stats
## Not run:
do_possession_stats_lineup(acb_combs, "Unicaja", "quintet", NULL, NULL)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.