
Last chance! 50% off unlimited learning
Sale ends in
This function plots a confussion matrix.
mplot_conf(
tag,
score,
thresh = 0.5,
abc = TRUE,
subtitle = NA,
model_name = NA,
save = FALSE,
subdir = NA,
file_name = "viz_conf_mat.png"
)
Vector. Real known label
Vector. Predicted value or model's result
Numeric. Value which splits the results for the confusion matrix.
Boolean. Arrange columns and rows alphabetically?
Character. Subtitle to show in plot
Character. Model's name
Boolean. Save output plot into working directory
Character. Sub directory on which you wish to save the plot
Character. File name as you wish to save the plot
You may use conf_mat()
to get calculate values.
Other ML Visualization:
mplot_cuts_error()
,
mplot_cuts()
,
mplot_density()
,
mplot_full()
,
mplot_gain()
,
mplot_importance()
,
mplot_lineal()
,
mplot_metrics()
,
mplot_response()
,
mplot_roc()
,
mplot_splits()
# NOT RUN {
options("lares.font" = NA) # Temporal
data(dfr) # Results for AutoML Predictions
lapply(dfr, head)
# Plot for Binomial Model
mplot_conf(dfr$class2$tag, dfr$class2$scores,
model_name = "Titanic Survived Model")
# Plot for Multi-Categorical Model
mplot_conf(dfr$class3$tag, dfr$class3$score,
model_name = "Titanic Class Model")
# }
Run the code above in your browser using DataLab