plot.interv_detect: Plot Test Statistic of Intervention Detection Procedure for...

View source: R/plot.interv_detect.R

plot.interv_detectR Documentation

Plot Test Statistic of Intervention Detection Procedure for Count Time Series Following Generalised Linear Models

Description

Provides a plot of the test statistics of a test on an intervention in GLM-type count time series (as returned by interv_detect.tsglm) against time.

Usage

## S3 method for class 'interv_detect'
plot(x, ...)

Arguments

x

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

...

additional arguments to be passed to function plot.

Author(s)

Tobias Liboschik and Philipp Probst

See Also

interv_detect for detecting an intervention effect in GLM-type count time series and tsglm for fitting such a model.

Examples

## Not run: 
###Campylobacter infections in Canada (see help("campy"))
campyfit <- tsglm(ts=campy, model=list(past_obs=1, past_mean=c(7,13)))
campyfit_intervdetect <- interv_detect(fit=campyfit, taus=80:120,
                        delta=1, external=FALSE)
#This example runs about 20 minutes on a single processing unit,
#of course depending on its speed.
plot(campyfit_intervdetect)
## End(Not run)

tscount documentation built on May 11, 2023, 3:04 p.m.