tvar {timsac} | R Documentation |
Estimate time varying coefficients AR model.
tvar(y, ar.order, trend.order=2, span, outlier, tau20=NULL, delta=NULL, plot=TRUE)
y |
a univariate time series. |
ar.order |
AR order. |
trend.order |
trend order (=1 or 2). |
span |
local stationary span. |
outlier |
positions of outliers. |
tau20 |
initial value for computing variance of the system noise tau2. |
delta |
delta for computing variance of the system noise tau2. If tau20 is NULL or delta is NULL, tau2 is computed automatically. |
plot |
logical. If TRUE (default) parcor is plotted. |
The time-varying coefficients AR model is given by
y(t) = a(1,t)y(t-1) + ... + a(p,t)y(t-p) + u(t)
where a(i,t) is i-lag AR coefficient at time t and u(t) is a zwro mean white noise.
tau2 |
variance of the system noise. |
sigma2 |
variance of the observational noise. |
lkhood |
log-likelihood. |
aic |
AIC. |
arcoef |
time varying AR coefficients. |
parcor |
partial autocorrelation coefficient. |
spec |
time varying spectrum. |
Kitagawa, G. (1993) Time series analysis programing (in Japanese). The Iwanami Computer Science Senes.
Kitagawa, G. and Gersch, W. (1996) Smoothness Priors Analysis of Time Series. Lecture Notes in Statistics, No.116, Springer-Verlag.
Kitagawa, G. and Gersch, W. (1985) A smoothness priors time varying AR coefficient modeling of nonstationary time series. IEEE trans. on Automatic Controle, AC-30, 48-56.
data(MYE1F) # an earthquake wave data z <- tvvar(MYE1F, trend.order=2, tau20= 6.6e-06, delta=1.0e-06, plot=FALSE) zz <- tvar(z$normdat, ar.order=4, trend.order=2, span=20, tau20=6.6e-06, delta=1.0e-06, outlier=c(630,1026)) zz$tau2 zz$sigma2 zz$lkhood zz$aic