Skip to contents

Get lineup statistics for a team-season from the CollegeBasketballData API.

Usage

cbbd_lineups_team(
  season = most_recent_mbb_season(),
  team,
  start_date_range = NULL,
  end_date_range = NULL
)

Arguments

season

(integer required): Season, 4-digit ending-year (e.g. 2024). Defaults to most_recent_mbb_season().

team

(character required): Team name (e.g. Duke).

start_date_range

(character optional): ISO 8601 start of date range.

end_date_range

(character optional): ISO 8601 end of date range.

Value

A hoopR_data tibble with one row per lineup. The athletes column is a list of lineup members; team_stats/opponent_stats are flattened into prefixed columns. Key identifying columns:

col_nametypesdescription
team_idintegerTeam id.
teamcharacterTeam name.
conferencecharacterConference name.
id_hashcharacterUnique hash identifying the lineup.
athleteslistList of athletes in the lineup.
total_secondsnumericTotal seconds the lineup played.
pacenumericLineup pace (possessions).
offense_ratingnumericLineup offensive rating.
defense_ratingnumericLineup defensive rating.
net_ratingnumericLineup net rating.

See also

Other CBD Lineups Functions: cbbd_lineups_game()

Examples

# \donttest{
  try(cbbd_lineups_team(season = 2024, team = "Duke"))
#>  2026-06-09 22:48:22.071742: Invalid arguments or no lineup data available for Duke!
#>  Args: season = 2024, team = "Duke", start_date_range = NULL, end_date_range = NULL
#>  Error: api.collegebasketballdata.com requires an API key.        See ?register_cbbd for details.
#> data frame with 0 columns and 0 rows
# }