TOPboxes | R Documentation |
Calculate Tbox, Obox and Pbox
TOPboxes(data, team)
data |
a play-by-play data frame |
team |
character, team |
A list with the following elements
Tbox
, (completare descrizione)
Obox
, (completare descrizione)
Pbox
, (completare descrizione)
Marco Sandri, Paola Zuccolotto, Marica Manisera (basketballanalyzer.help@unibs.it)
P. Zuccolotto and M. Manisera (2020) Basketball Data Science: With Applications in R. CRC Press.
PbPmanipulation
library(operators)
library(dplyr)
PbP <- PbPmanipulation(PbP.BDB)
PbP <- PbP %>%
mutate(oreb = type %~% "rebound offensive",
dreb = type %~% "rebound defensive",
turnover = event_type=="turnover",
PF = (event_type == "foul") & !(type %~% "technical") ) %>%
mutate(across(c(player, assist, steal, block, h1:h5, a1:a5), as.character)) %>%
as.data.frame()
out <- TOPboxes(PbP, team="GSW")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.