Learn R Programming

BAwiR (version 1.3.4)

do_ft_fouls: Compute free throw fouls

Description

Compute how many 1-,2- and 3-free throw fouls has committed or received every player.

Usage

do_ft_fouls(data, type)

Value

Data frame with the following columns:

  • team: Name of the team. player: Name of the player. n_ft_fouls_x: Number of free throw fouls committed or received. n_ft_x: Number of free throws given or got. n_ft_char: Type of free throw. Options can be 1TL, 2TL and 3TL. n: Number of free throws of each type.

Arguments

data

Play-by-play data.

type

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

Author

Guillermo Vinue

Examples

Run this code
df01 <- do_ft_fouls(acb_vbc_cz_pbp_2223, "comm")
#df01  
 
df02 <- do_ft_fouls(acb_vbc_cz_pbp_2223, "rec")
#df02

Run the code above in your browser using DataLab