arma.spec {astsa} | R Documentation |
Gives the ARMA spectrum, tests for causality, invertibility, and common zeros.
arma.spec(ar = 0, ma = 0, var.noise = 1, n.freq = 500, main='from specified model', frequency=1, ...)
ar |
vector of AR parameters |
ma |
vector of MA parameters |
var.noise |
variance of the noise |
n.freq |
number of frequencies |
main |
title of graphic |
frequency |
for seasonal models, adjusts the frequency scale |
... |
additional arguments |
The basic call is arma.spec(ar, ma)
where ar
and ma
are vectors
containing the model parameters. Use log='y'
if you want the plot on
a log scale. If the model is not causal or invertible an error message is given. If
there are approximate common zeros, a spectrum will be displayed and a warning will be given;
e.g., arma.spec(ar= .9, ma= -.9)
will yield a warning and the plot will be the
spectrum of white noise.
freq |
frequencies - returned invisibly |
spec |
spectral ordinates - returned invisibly |
D.S. Stoffer
You can find demonstrations of astsa capabilities at FUN WITH ASTSA.
The most recent version of the package can be found at https://github.com/nickpoison/astsa/.
In addition, the News and ChangeLog files are at https://github.com/nickpoison/astsa/blob/master/NEWS.md.
The webpages for the texts are https://www.stat.pitt.edu/stoffer/tsa4/ and https://www.stat.pitt.edu/stoffer/tsda/.
arma.spec(ar = c(1, -.9), ma = .8) arma.spec(ar = c(1, -.9), log='y') arma.spec(ar = c(1, -.9), main='AR(2)', gg=TRUE, col=5, lwd=2) arma.spec(ar=c(rep(0,11),.4), ma=.5, col=5, lwd=3, frequency=12)