Learn R Programming

ggfortify (version 0.4.17)

autoplot.cpt: Autoplot changepoint::cpt

Description

Autoplot changepoint::cpt

Usage

# S3 method for cpt
autoplot(
  object,
  is.date = NULL,
  cpt.colour = "#FF0000",
  cpt.linetype = "dashed",
  ...
)

Value

ggplot

Arguments

object

changepoint::cpt instance

is.date

Logical frag indicates whether the stats::ts is date or not. If not provided, regard the input as date when the frequency is 4 or 12.

cpt.colour

Line colour for changepoints

cpt.linetype

Line type for changepoints

...

other arguments passed autoplot.ts

Examples

Run this code
if (FALSE) {
library(changepoint)
autoplot(cpt.mean(AirPassengers))
autoplot(cpt.meanvar(AirPassengers))
}

Run the code above in your browser using DataLab