plot_permutation() takes the results of test_permutation() and plots the distribution of permuted partitions compared to the observed partition.

plot_permutation(
  permutations,
  .plot = c("information", "nclusters", "nreduced"),
  labeller = "target information:",
  perm_color = "#56B4EA",
  obs_color = "#CC78A8",
  geom = ggplot2::geom_density
)

Arguments

permutations

a tibble, the result of test_permutation()

.plot

the variable to plot: observed information, the number of clusters created, or the number of observed variables reduced

labeller

the facet label

perm_color

the color of the permutation fill

obs_color

the color of the observed statistic line

geom

the geom to use. The default is geom_density.

Value

a ggplot