Wrapper around the algo.cusum_with_reset Copied from the code of the surveillance package and adapted for algo.cusum_with_reset
cusum_with_reset.RdWrapper around the algo.cusum_with_reset Copied from the code of the surveillance package and adapted for algo.cusum_with_reset
Usage
cusum_with_reset(
sts,
control = list(range = range, k = 1.04, h = 2.26, m = NULL, trans = "standard", alpha =
NULL),
...
)Arguments
- sts
surveillance::sts() format of aggregated timeseries of case counts
- control
control object:
rangedetermines the desired time points which should be evaluated
kis the reference value
hthe decision boundary
mhow to determine the expected number of cases – the following arguments are possible
numerica vector of values having the same length as
range. If a single numeric value is specified then this value is replicatedlength(range)times.NULLA single value is estimated by taking the mean of all observations previous to the first
rangevalue."glm"A GLM of the form $$\log(m_t) = \alpha + \beta t + \sum_{s=1}^S (\gamma_s \sin(\omega_s t) + \delta_s \cos(\omega_s t)),$$ where \(\omega_s = \frac{2\pi}{52}s\) are the Fourier frequencies is fitted. Then this model is used to predict the
rangevalues.
transone of the following transformations (warning: Anscombe and NegBin transformations are experimental)
rossistandardized variables z3 as proposed by Rossi
standardstandardized variables z1 (based on asymptotic normality) - This is the default.
anscombeanscombe residuals – experimental
anscombe2ndanscombe residuals as in Pierce and Schafer (1986) based on 2nd order approximation of E(X) – experimental
pearsonNegBincompute Pearson residuals for NegBin – experimental
anscombeNegBinanscombe residuals for NegBin – experimental
noneno transformation
alphaparameter of the negative binomial distribution, s.t. the variance is \(m+\alpha *m^2\)
- ...
any additional parameters which should be passed onto wrap.algo