plot.oCPD() produces a summary plot of the results of onlineCPD(). Results are somewhat hard to interpret, see Details
"plot"(x, lines = TRUE, title = "", leg.name = "Variable", cleanCP = TRUE, buffer = 10, ...)onlineCPD or offlineCPD
x$data.
findCP to remove some changepoints
The top plot is the data plotted as a scatterplot, with each data column in a different colour. If lines == TRUE then red vertical lines will be plotted to delineate the different runs.
The bottom plot shows the algorithms results. The black smears show the probability that run length is a particular value on the y-axis at the time on the x-axis. That is, for each pair (x,y), the darkness is the probability that at time x the run length is y. If run continues, the smear continues to move diagonally up. If the run stops, the smear returns to zero on the y-axis. The red diagonal line plots the largest probability at each time. Note the log scale on Probability.
If time was not NULL in the call to offlineCPD, then time will be along the x-axis of both plots.
See findCP for information on which changepoints will be removed if cleanCP is true.
findCP for information on how changepoints are reduced
set.seed(6)
x <- c(rnorm(50,mean=0.3,sd=0.15),rnorm(40,mean=0.7,sd=0.1),rnorm(60,mean=0.5,sd=0.15))
plot(offlineCPD(x))
Run the code above in your browser using DataLab