algo.outbreakP: Semiparametric surveillance of outbreaks

Description Usage Arguments Details Value Author(s) Source References Examples

Description

Frisen and Andersson (2009) method for semiparametric surveillance of outbreaks

Usage

1
2
    algo.outbreakP(disProgObj, control = list(range = range, k=100,
                   ret=c("cases","value"),maxUpperboundCases=1e5))

Arguments

disProgObj

object of class disProg (including the observed and the state chain).

control

A list controlling the behaviour of the algorithm

range

determines the desired time-points which should be monitored. Note that it is automatically assumed that ALL other values in disProgObj can be used for the estimation, i.e. for a specific value i in range all values from 1 to i are used for estimation.

k

The threshold value. Once the outbreak statistic is above this threshold k an alarm is sounded.

ret

a string specifying the type of upperbound-statistic that is returned. With "cases" the number of cases that would have been necessary to produce an alarm (NNBA) or with "value" the outbreakP-statistic is computed (see below).

maxUpperboundCases

Upperbound when numerically searching for NNBA. Default is 1e5.

Details

A generalized likelihood ratio test based on the Poisson distribution is implemented where the means of the in-control and out-of-control states are computed by isotonic regression.

OutbreakP(s) = ∏_{t=1}^s ≤ft( \frac{\hat{μ}^{C1}(t)}{\hat{μ}^D(t)} \right)^{x(t)}

,

where \hat{μ}^{C1}(t) is the estimated mean obtained by uni-modal regression under the assumption of one change-point and \hat{μ}^D(t) is the estimated result when there is no change-point (i.e. this is just the mean of all observations). Note that the contrasted hypothesis assume all means are equal until the change-point, i.e. this detection method is especially suited for detecting a shift from a relative constant mean. Hence, this is less suited for detection in diseases with strong seasonal endemic component. Onset of influenza detection is an example where this method works particular well.

In case control$ret == "cases" then a brute force numerical search for the number needed before alarm (NNBA) is performed. That is, given the past observations, whats the minimum number which would have caused an alarm? Note: Computing this might take a while because the search is done by sequentially increasing/decreasing the last observation by one for each time point in control$range and then calling the workhorse function of the algorithm again. The argument control$maxUpperboundCases controls the upper limit of this search (default is 1e5). Currently, even though the statistic has passed the threshold, the NNBA is still computed. After a few time instances what typically happens is that no matter the observed value we would have an alarm at this time point. In this case the value of NNBA is set to NA. Furthermore, the first time point is always NA, unless k<1.

Value

survRes

algo.outbreakP gives a list of class survRes which includes the vector of alarm values for every time-point in range, the vector of threshold values for every time-point in range.

Author(s)

M. H̦hle Рbased on Java code by M. Frisen and L. Schi̦ler

Source

The code is an extended R port of the Java code by Marianne Frisén and Linus Schiöler from the CASE project available under the GNU GPL License v3. See https://case.folkhalsomyndigheten.se/ for further details on the CASE project. A manual on how to use an Excel implementation of the method is available at http://economics.handels.gu.se/english/Units+and+Centra/statistical_research_unit/software.

An additional feature of the R code is that it contains a search for NNBA (see details).

References

Frisén, M., Andersson and Schiöler, L., (2009), Robust outbreak surveillance of epidemics in Sweden, Statistics in Medicine, 28(3):476-493.

Frisén, M. and Andersson, E., (2009) Semiparametric Surveillance of Monotonic Changes, Sequential Analysis 28(4):434-454.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
#Use data from outbreakP manual (http://www.hgu.gu.se/item.aspx?id=16857)
y <- matrix(c(1,0,3,1,2,3,5,4,7,3,5,8,16,23,33,34,48),ncol=1)

#Generate sts object with these observations
mysts <- new("sts", observed=y, epoch=1:length(y), alarm=y*0,
                    start=c(2000,1), freq=52)

#Run the algorithm and present results
#Only the value of outbreakP statistic
upperbound(outbreakP(mysts, control=list(range=1:length(y),k=100,
           ret="value")))

#Graphical illustration with number-needed-before-alarm (NNBA) upperbound.
res <- outbreakP(mysts, control=list(range=1:length(y),k=100,
           ret="cases"))
plot(res,dx.upperbound=0,lwd=c(1,1,3),legend.opts=list(legend=c("Infected",
      "NNBA","Outbreak","Alarm"),horiz=TRUE))

jimhester/surveillance documentation built on May 19, 2019, 10:33 a.m.