View source: R/class-seg_basket.R
plot_best_chromosome | R Documentation |
seg_basket
objectsDiagnostic plots for seg_basket
objects
plot_best_chromosome(x)
plot_cpt_repeated(x, i = nrow(x$basket))
x |
A |
i |
index of basket to show |
seg_basket()
objects contain baskets of candidate changepoint sets.
plot_best_chromosome()
shows how the size of the candidate changepoint
sets change across the generations of evolution.
plot_cpt_repeated()
shows how frequently individual observations appear in
the best candidate changepoint sets in each generation.
A ggplot2::ggplot()
object
# Segment a time series using Coen's algorithm
x <- segment(DataCPSim, method = "coen", num_generations = 3)
# Plot the size of the sets during the evolution
x |>
as.segmenter() |>
plot_best_chromosome()
# Segment a time series using Coen's algorithm
x <- segment(DataCPSim, method = "coen", num_generations = 3)
# Plot overall frequency of appearance of changepoints
plot_cpt_repeated(x$segmenter)
# Plot frequency of appearance only up to a specific generation
plot_cpt_repeated(x$segmenter, 5)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.