50% off | Unlimited Data & AI Learning

Last chance! 50% off unlimited learning

Sale ends in


BAwiR (version 1.3.4)

do_offensive_fouls: Compute offensive fouls

Description

Compute how many offensive fouls has committed or received every player.

Usage

do_offensive_fouls(data, type)

Value

Data frame with the following columns:

  • team: Name of the team. player: Name of the player. n_offensive_fouls_x: Number of offensive fouls.

Arguments

data

Play-by-play data.

type

Either 'comm' (for committed) or 'rec' (for received).

Author

Guillermo Vinue

Examples

Run this code
df01 <- do_offensive_fouls(acb_vbc_cz_pbp_2223, "comm")
#df01

df02 <- do_offensive_fouls(acb_vbc_cz_pbp_2223, "rec")
#df02

Run the code above in your browser using DataLab