Learn R Programming

not (version 1.6)

plot.not: Plot a 'not' object

Description

Plots the input vector used to generate 'not' object x with the signal fitted with predict.not.

Usage

# S3 method for not
plot(x, ...)

Arguments

x

An object of class 'not', returned by not.

...

Further parameters which may be passed to predict.not and features.

See Also

predict.not not features

Examples

Run this code
# **** Piecewisce-constant mean with Gaussian noise.
x <- c(rep(0, 100), rep(1,100)) + rnorm(100)
# *** identify potential locations of the change-points
w <- not(x, contrast = "pcwsConstMean")
# *** when 'cpt' is omitted, 'features' function is used internally 
# to choose change-points locations
plot(w)
# *** estimate and plot the signal specifying the location of the change-point
plot(w, cpt=100)

Run the code above in your browser using DataLab