an optional vector specifying a subset of observations to be highlighted in the graph or subset='quant' to highligh observations with coordinates above and below the upper and lower quantiles of the variables on the x- and y-axis (Lx, Ux, Ly, Uy).
Lx
numeric; if subset='quant', lower quantile for the variable on the x-axis (default = 0.01).
Ux
numeric; if subset='quant', upper quantile for the variable on the x-axis (default = 0.99).
Ly
numeric; if subset='quant', lower quantile for the variable on the y-axis (default = 0.01).
Uy
numeric; if subset='quant', upper quantile for the variable on the y-axis (default = 0.99).
title
character, plot title.
xtitle
character, x-axis label.
ytitle
character, y-axis label.
repel
logical, if TRUE (the default) text labels repel away from each other.
...
other graphical parameters.
Value
A ggplot2 object
References
P. Zuccolotto and M. Manisera (2020) Basketball Data Science: With Applications in R. CRC Press.
# NOT RUN {Pbox.sel <- subset(Pbox, MIN >= 500)
X <- Pbox.sel$AST/Pbox.sel$MIN
Y <- Pbox.sel$TOV/Pbox.sel$MIN
Pl <- Pbox.sel$Player
mod <- simplereg(x=X, y=Y, type="lin")
plot(mod)
# }