Learn R Programming

VGAM (version 0.7-1)

rrar: Nested reduced-rank autoregressive models for multiple time series

Description

Estimates the parameters of a nested reduced-rank autoregressive model for multiple time series.

Usage

rrar(Ranks = 1, coefstart = NULL)

Arguments

Value

  • An object of class "vglmff" (see vglmff-class). The object is used by modelling functions such as vglm and vgam.

Details

Full details are given in Ahn and Reinsel (1988). Convergence may be very slow, so setting maxits=50, say, may help. If convergence is not obtained, you might like to try inputting different initial values.

Setting trace=TRUE in vglm is useful for monitoring the progress at each iteration.

References

Ahn, S. and Reinsel, G. C. (1988) Nested reduced-rank autoregressive models for multiple time series. Journal of the American Statistical Association, 83, 849--856.

Documentation accompanying the VGAM package at http://www.stat.auckland.ac.nz/~yee contains further information and examples.

See Also

vglm, usagrain.

Examples

Run this code
data(usagrain)
year = seq(1961+1/12, 1972+10/12, by=1/12)
par(mar=c(4,4,2,2)+0.1, mfrow=c(2,2))
for(i in 1:4) {
    plot(year, usagrain[,i], main=names(usagrain)[i], type="l", xlab="", ylab="")
    points(year, usagrain[,i], pch="*")
}
apply(usagrain, 2, mean)     # mu vector
cgrain = scale(usagrain, scale=FALSE) # Center the time series only
fit = vglm(cgrain ~ 1, rrar(Ranks=c(4,1)), trace=TRUE)
summary(fit)

print(fit@misc$Ak1, dig=2)
print(fit@misc$Cmatrices, dig=3)
print(fit@misc$Dmatrices, dig=3)
print(fit@misc$omegahat, dig=3)
print(fit@misc$Phimatrices, dig=2)

par(mar=c(4,4,2,2)+0.1, mfrow=c(4,1))
for(i in 1:4) {
    plot(year, fit@misc$Z[,i], main=paste("Z", i, sep=""),
         type="l", xlab="", ylab="")
    points(year, fit@misc$Z[,i], pch="*")
}

Run the code above in your browser using DataLab