Approximate Conditional Mean Robust Filter

DESCRIPTION:

Applies an approximate conditional mean type robust filter to a univariate time series. The filtered series (component filt of the output) will be free of outliers.

USAGE:

acm.filt(x, gm, s0=0, iter=1, a=2.5, b=5.0, psiovw=T,  
        bottom=T, saves1=T) 

REQUIRED ARGUMENTS:

x
univariate time series or vector. Missing values are not allowed.
gm
list as produced by the ar.gm function which includes components ar containing AR coefficient estimates, sinnov containing innovation scale estimates from AR fits of orders 1 through order, chat containing an estimate of the order by order autocovariance matrix, and rmu, the estimated mean of x. Both ar and sinnov are vectors of length order.

OPTIONAL ARGUMENTS:

s0
scale of the nominal Gaussian component of the additive noise.
iter
number of iterations to be computed.
a
first break point for the Hampel two-part psi used in filtering.
b
second break point for the Hampel two-part psi used in filtering; psi(t) = 0 for t > b.
psiovw
logical flag: if TRUE, use psi(t)/t to calculate the weight function w(t); if FALSE, use psi'(t).
bottom
logical flag: if TRUE, filtering from the bottom of xhats is performed, in which case lag p-1 smoothing is performed. If FALSE, filtering is from the top. The vector xhats contains estimates of x(t), x(t-1),..., x(t-p+1) at time t.
saves1
logical flag: if TRUE, the time varying scale st will be (M(t)[1,1] + v0)^.5, where v0 = s0*s0. If FALSE, st will be the square root of the appropriate element of P(t). P(t) is the covariance matrix of the error in xhats, and M(t) is a one-step prediction error covariance matrix.

VALUE:

a list with the following components:
ar
vector of length order (= length(gm$ar)) containing estimates of the autoregression parameters computed via least squares from the filtered data.
chat
an order by order Toeplitz matrix containing an estimate of the autocovariance matrix of the filtered data.
si
estimate of the innovations scale computed from the filtered data.
filt
vector or time series containing the filtered data.
st
vector or time series containing time varying scale estimates determined by the input argument saves1.

REFERENCES:

Martin, R. D. and Thomson, D. J. (1982). Robust resistant spectrum estimates. Proceedings of the IEEE 70, 1097-1115.

Martin, R. D. (1981). Robust methods for time series. In Applied Time Series Analysis II. D. F. Findley, ed. Academic Press, New York. pp. 683-759.

The chapter "Analyzing Time Series" of the S-PLUS Guide to Statistical and Mathematical Analysis.

SEE ALSO:

, , .

EXAMPLES:

gm <- ar.gm(bicoal.tons, 3); acm.filt(bicoal.tons, gm)