plot.bcpa: Plotting method for BCPA output

Description Usage Arguments Author(s) See Also Examples

Description

Plotting method for the output of a BCPA analysis with vertical break points, superimposed estimates of the partitioned mean and variance estimates and color-coded autocorrelation estimates.

Usage

1
2
3
4
5
## S3 method for class 'bcpa'
plot(x, type = c("smooth", "flat")[1], threshold = 3,
  clusterwidth = 1, col.cp = rgb(0.5, 0, 0.5, 0.5), pt.cex = 0.5,
  legend = TRUE, rho.where = "topleft", mu.where = "nowhere",
  col.sd = "red", col.mean = "black", ...)

Arguments

x

a windowsweep object, i.e. the output of the WindowSweep function.

type

whether to plot smooth or flat bcpa output

threshold

for smooth BCPA, this is the minimum number of windows that must have identified a given changepoint to be illustrated.

clusterwidth

for flat BCPA, this is the temporal range within which change points are considered to be within the same cluster.

col.cp,col.mean,col.sd

color of the vertical change points, mean estimate, and prediction interval (mu +- sigma), respectively.

pt.cex

expansion coefficient for point sizes.

legend

logical - whether to draw a legend or not.

rho.where

where to place the legend for the time-scale / auto-correlation. Can be one of "nowhere", "top", "bottom", "left", "right", "topleft", "topright", "bottomright", "bottomleft"

mu.where

where (and whether) to place the legend box for the mean - same options as for rho.where

...

other arguments to pass to the plot base function.

Author(s)

Eliezer Gurarie

See Also

Plots output of the WindowSweep function.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
if(!exists("Simp.ws"))
{
 data(Simp)
 Simp.ws <- WindowSweep(GetVT(Simp), "V*cos(Theta)", windowsize = 50, windowstep = 1, progress=TRUE)
}

plot(Simp.ws)
# this actually provides basically the exact original changepoints
plot(Simp.ws, threshold=7)
# here's a flat analysis
plot(Simp.ws, type="flat", clusterwidth=3, legend=FALSE)

Example output

Loading required package: Rcpp
Loading required package: plyr

  |                                                                            
  |                                                                      |   0%
  |                                                                            
  |=====                                                                 |   7%
  |                                                                            
  |=========                                                             |  14%
  |                                                                            
  |==============                                                        |  20%
  |                                                                            
  |===================                                                   |  27%
  |                                                                            
  |========================                                              |  34%
  |                                                                            
  |============================                                          |  41%
  |                                                                            
  |=================================                                     |  47%
  |                                                                            
  |======================================                                |  54%
  |                                                                            
  |===========================================                           |  61%
  |                                                                            
  |===============================================                       |  68%
  |                                                                            
  |====================================================                  |  74%
  |                                                                            
  |=========================================================             |  81%
  |                                                                            
  |=============================================================         |  88%
  |                                                                            
  |==================================================================    |  95%
Warning message:
In plot.xy(xy.coords(x, y), type = type, ...) :
  plot type 'black' will be truncated to first character
Warning message:
In plot.xy(xy.coords(x, y), type = type, ...) :
  plot type 'black' will be truncated to first character

bcpa documentation built on May 1, 2019, 10:30 p.m.