outliers.tfm: Outliers detection at known/unknown dates
Description
outliers performs a detection of four types of anomalies (AO, TC, LS
and IO) in a time series described by an ARIMA model. If the dates of the
outliers are unknown, an iterative detection process like that proposed by
Chen and Liu (1993) is conducted.
Usage
# S3 method for tfm
outliers(
mdl,
y = NULL,
dates = NULL,
c = 3,
calendar = FALSE,
easter = FALSE,
n.ahead = NULL,
p.value = 1,
...
)
outliers(mdl, ...)
# S3 method for um
outliers(
mdl,
z = NULL,
dates = NULL,
c = 3,
calendar = FALSE,
easter = FALSE,
n.ahead = 0,
p.value = 1,
...
)
a list of dates c(year, season). If dates = NULL, an
iterative detection process is conducted.
c
a positive constant to compare the z-ratio of the effect of an
observation and decide whether or not it is an outlier. This argument is
only used when dates = NULL.
calendar
logical; if true, calendar effects are also estimated.
easter
logical; if true, Easter effect is also estimated.
n.ahead
a positive integer to extend the sample period of the
intervation variables with n.ahead observations, which could be
necessary to forecast the output.
p.value
estimates with a p-value greater than p.value are omitted.