Description Usage Arguments Details Value Author(s) Examples
View source: R/lineups_data_adjustment.R
The function transform the statistics entered for later use in the rest of the functions that apply to lineup statistics.
1 |
df1 |
Should be a Data Frame |
The data.frame must have the same columns and these represent the same as in the example.
The function allows the transformation of the basic statistics of the lineups to which the shooting percentages, the total rebounds and the plus minus.
The function allows the transformation of the extended statistics of the lineups to which the total rebounds and the plus minus.
The data frame obtained for the basic statistics of lineups will have the following format:
Point Guard (PG)
Shooting Guard (SG)
Small Forward (SF)
Paint Forward (PF)
Center (C)
Games played (G)
Games Started (GS)
Minutes Played (MP)
Field Goals Made (FG)
Field Goals Attempted (FGA)
Field Goals Percentage (FG
Three Points Made (3P)
Three Points Attempted (3PA)
Three Points Percentage (3P%)
Two Points Made (2P)
Two Points Attempted (2PA)
Free Throw Made (FT)
Offensive Rebounds (ORB)
Defensive Rebounds (DRB)
Total Rebounds (TRB)
Assists (AST)
Steals (STL)
Blocks (BLK)
Turnover (TOV)
Personal Fouls (PF)
Points (PTS)
Plus (+)
Minus (-)
Plus Minus (+/-)
For the extended statistics of the lineups it will have the same format as the basic statistics of the lineups but adding the statistics of the opponent against that lineups.
Fco Javier Cantero fco.cantero@edu.uah.es
Juan José Cuadrado jjcg@uah.es
Universidad de Alcalá de Henares
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | df1 <- data.frame("PG"= c("James","Rondo"),"SG" = c("Green","Caruso"),
"SF" = c("Caldwell","Kuzma"), "PF" = c("Davis","Davis"),
"C" = c("Howard ","Howard"),"MP" = c(7,1), "FG " = c(4,0),
"FGA" = c(7,0), "X3P" = c(0,0),"X3PA" = c(2,0),"X2P" = c(4,0),
"X2PA" = c(5,0), "FT" = c(1,0), "FTA" = c(3,0),"ORB" = c(2,0),
"DRB" = c(5,0), "AST " = c(2,0), "STL " = c(1,0), "BLK " = c(0,0),
"TOV " = c(7,2), "PF" = c(1,0), "PLUS" = c(9,0),"MINUS" = c(17,3))
lineups_data_adjustment(df1)
df1 <- data.frame("PG" = c("James","Rondo"),"SG"= c("Green","Caruso"),
"SF" = c("Caldwell","Kuzma"), "PF" = c("Davis","Davis"),
"C" = c("Howard ","Howard"),"MP" = c(7,1), "FG " = c(6,0),
"OppFG " = c(6,0), "FGA " = c(10,0),"OppFGA " = c(9,0),
"X3P " = c(2,0),"Opp3P " = c(1,0),"X3PA " = c(4,0),
"Opp3PA ç" = c(3,0),"X2P" = c(4,0),"Opp2P" = c(5,0),"X2PA " = c(6,0),
"Opp2PA" = c(8,0) , "FT " = c(0,0),"OppFT " = c(1,0), "FTA " = c(0,0),
"OppFTA" = c(1,0),"OppRB" = c(2,0),"OppOppRB" = c(1,0),"DRB" = c(4,0),
"OppDRB" = c(1,0),"AST " = c(5,0),"OppAST " = c(4,0),"STL" = c(1,0),
"OppSTL" = c(3,0),"BLK" = c(0,0),"OppBLK" = c(1,0),"TOppV" = c(5,2),
"OppTOppV" = c(3,2),"PF" = c(1,0),"OppPF" = c(3,0),"PLUS" = c(15,0),
"MINUS" = c(14,3))
lineups_data_adjustment(df1)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.