plot.interv_multiple: Plot for Iterative Intervention Detection Procedure for Count...

Description Usage Arguments Details Author(s) See Also Examples

View source: R/plot.interv_multiple.R

Description

Provides a plot with the intervention effects detected by an iterative procedure (as returned by interv_multiple.tsglm) and the time series cleaned from these intervention effects.

Usage

1
2
## S3 method for class 'interv_multiple'
plot(x, ...)

Arguments

x

an object of class "interv_multiple", usually a result of a call to interv_detect.

...

additional arguments to be passed to function plot.

Details

The vertical red lines indicate where possible interventions were found and the dashed blue line is the time series cleaned from all detected intervention effects.

Author(s)

Tobias Liboschik and Philipp Probst

See Also

interv_multiple for detecting multiple intervention effects in GLM-type count time series and tsglm for fitting such a model.

Examples

1
2
3
4
5
6
7
8
## Not run: 
###Campylobacter infections in Canada (see help("campy"))
campyfit <- tsglm(ts=campy, model=list(past_obs=1, past_mean=c(7,13)))
campyfit_intervmultiple <- interv_multiple(fit=campyfit, taus=80:120,
                              deltas=c(0,0.8,1), external=FALSE, B=2,
                              signif_level=0.05) #runs several hours!
plot(campyfit_intervmultiple)
## End(Not run)

tscount documentation built on Sept. 8, 2020, 9:08 a.m.