We have a new R WVPlots plot:
ROCPlotPairList. It is useful for comparing the ROC/AUC of multiple models on the same data set.
library(WVPlots) set.seed(34903490) x1 <- rnorm(50) x2 <- rnorm(length(x1)) x3 <- rnorm(length(x1)) y <- 0.2*x2^2 + 0.5*x2 + x1 + rnorm(length(x1)) frm <- data.frame( x1 = x1, x2 = x2, x3 = x3, yC = y >= as.numeric(quantile(y, probs=0.8))) WVPlots::ROCPlotPairList( frame = frm, xvar_names = qc(x1, x2, x3), truthVar = "yC", truthTarget = TRUE, title = "Example ROC list plot")
Please check it out.
Categories: Administrativia Statistics Tutorials
Data Scientist and trainer at Win Vector LLC. One of the authors of Practical Data Science with R.
Great!! Thanks for sharing. I’ve got a similar function to plot single or multiple categorical values on a single model: https://laresbernardo.github.io/lares/reference/mplot_roc.html