Description Usage Arguments References Examples
The function takes range
values of the surveillance time
series sts
and for each time point uses a Bayesian model of the negative binomial family with
log link inspired by the work of Noufaily et al. (2012) and of Manitz and Höhle (2014). It allows delaycorrected aberration detection as explained in Salmon et al. (2015). A reportingTriangle
has to be provided in the control
slot.
1 2 3 4 5 6 
sts 
stsobject to be analysed. Needs to have a reporting triangle. 
control 
list of control arguments:

Farrington, C.P., Andrews, N.J, Beale A.D. and Catchpole, M.A. (1996): A statistical algorithm for the early detection of outbreaks of infectious disease. J. R. Statist. Soc. A, 159, 547563.
Noufaily, A., Enki, D.G., Farrington, C.P., Garthwaite, P., Andrews, N.J., Charlett, A. (2012): An improved algorithm for outbreak detection in multiple surveillance systems. Statistics in Medicine, 32 (7), 12061222.
Salmon, M., Schumacher, D., Stark, K., Höhle, M. (2015): Bayesian outbreak detection in the presence of reporting delays. Biometrical Journal, 57 (6), 10511067.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52  ## Not run:
data("stsNewport")
salm.Normal < list()
salmDelayAsym < list()
for (week in 43:45){
listWeeks < as.Date(row.names(stsNewport@control$reportingTriangle$n))
dateObs < listWeeks[isoWeekYear(listWeeks)$ISOYear==2011 &
isoWeekYear(listWeeks)$ISOWeek==week]
stsC < sts_observation(stsNewport,
dateObservation=dateObs,
cut=TRUE)
inWeeks < with(isoWeekYear(epoch(stsC)),
ISOYear == 2011 & ISOWeek >= 40 & ISOWeek <= 48)
rangeTest < which(inWeeks)
alpha < 0.07
# Control slot for Noufaily method
controlNoufaily < list(range=rangeTest,noPeriods=10,
b=4,w=3,weightsThreshold=2.58,pastWeeksNotIncluded=26,
pThresholdTrend=1,thresholdMethod="nbPlugin",alpha=alpha*2,
limit54=c(0,50))
# Control slot for the Proposed algorithm with D=0 correction
controlNormal < list(range = rangeTest, b = 4, w = 3,
reweight = TRUE, mc.munu=10000, mc.y=100,
verbose = FALSE,
alpha = alpha, trend = TRUE,
limit54=c(0,50),
noPeriods = 10, pastWeeksNotIncluded = 26,
delay=FALSE)
# Control slot for the Proposed algorithm with D=10 correction
controlDelayNorm < list(range = rangeTest, b = 4, w = 3,
reweight = FALSE, mc.munu=10000, mc.y=100,
verbose = FALSE,
alpha = alpha, trend = TRUE,
limit54=c(0,50),
noPeriods = 10, pastWeeksNotIncluded = 26,
delay=TRUE,inferenceMethod="asym")
set.seed(1)
salm.Normal[[week]] < farringtonFlexible(stsC, controlNoufaily)
salmDelayAsym[[week]] < bodaDelay(stsC, controlDelayNorm)
}
opar < par(mfrow=c(2,3))
lapply(salmDelayAsym[c(43,44,45)],plot, legend=NULL, main="", ylim=c(0,35))
lapply(salm.Normal[c(43,44,45)],plot, legend=NULL, main="", ylim=c(0,35))
par(opar)
## End(Not run)

Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.