stsXtrct: Extraction and Subsetting of 'sts' objects

Description Methods Examples

Description

Methods for "[", i.e., extraction or subsetting of the "sts" class in package surveillance.

Note that [<--methods methods (i.e. subassigments) are currently not supported.

drop is always FALSE.

Methods

There are more than these:

x = "sts", i = "missing", j = "missing", drop= "ANY"

...

x = "sts", i = "numeric", j = "missing", drop= "missing"

...

x = "sts", i = "missing", j = "numeric", drop= "missing"

...

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
data("ha.sts")
haagg <- aggregate(ha.sts, nfreq=13)

#A suite of of simple tests (inspired by the Matrix package)
#stopifnot(identical(ha.sts, ha.sts[]))


plot(haagg[, 3])       # Single series
plot(haagg[1:30, 3])   # Somewhat shorter

#Counts at time 20
plot(haagg[20, ], type = observed ~1 |unit)

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