heat_map | R Documentation |
Create graphics for one or more confusion matrices
heat_map(x, title = NULL, title_col = 1, proportions = TRUE, annotate = TRUE)
x |
|
title |
character or NULL, for the plot title |
title_col |
character or integer, the column from which to draw the title when providing a data frame of confusion matrices |
proportions |
logical if TRUE annotate with proportions (as percentages) |
annotate |
logical if TRUE annotate with a caption of stats (acc, sens, spec) |
ggplot object ala conf_mat
## Not run: library(dplyr) data("hpc_cv") cm <- dplyr::as_tibble(hpc_cv) |> dplyr::filter(Resample %in% sprintf("Fold%0.2i", 1:4)) |> dplyr::group_by(Resample) |> yardstick::conf_mat(obs, pred) gg <- heat_map(cm) patchwork::wrap_plots(gg, ncol = 2) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.