do_possession_stats_lineup: Possessions-related statistics for lineups

View source: R/do_possession_stats_lineup.R

do_possession_stats_lineupR Documentation

Possessions-related statistics for lineups

Description

Compute the possessions-related statistics for lineups. These statistics are offensive rating, defensive rating, net rating, pace and number of possessions.

Usage

do_possession_stats_lineup(data_combs, team_name, type_lineup, type_period, type_opponent, 
                           cols_group = c("team", "lineup"))

Arguments

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").

Details

See https://www.basketball-reference.com/about/glossary.html for formulas and explanations.

Value

A data frame with the possessions statistics for each lineup.

Author(s)

Guillermo Vinue

See Also

do_possession_stats

Examples

## Not run: 
do_possession_stats_lineup(acb_combs, "Unicaja", "quintet", NULL, NULL)

## End(Not run)


BAwiR documentation built on Feb. 27, 2026, 5:07 p.m.