astsa (version 1.10)

arma.spec: Spectral Density of an ARMA Model

Description

Gives the ARMA spectrum, tests for causality, invertibility, and common zeros.

Usage

arma.spec(ar = 0, ma = 0, var.noise = 1, n.freq = 500, log="n", type=NULL, ...)

Arguments

ar

vector of AR parameters

ma

vector of MA parameters

var.noise

variance of the noise

n.freq

number of frequencies

log

plot spectra on a log-scale; default is 'no'

type

type of plot to be drawn, defaults to lines

additional arguments

Value

freq

frequencies - returned invisibly

spec

spectral ordinates - returned invisibly

%% ~Describe the value returned %% If it is a LIST, use %% \item{comp1 }{Description of 'comp1'} %% \item{comp2 }{Description of 'comp2'} %% ...

Details

The basic call is arma.spec(ar, ma) where ar and ma are vectors containing the model parameters. Use log="yes" 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 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.

References

http://www.stat.pitt.edu/stoffer/tsa4/ and http://www.stat.pitt.edu/stoffer/tsda/

Examples

Run this code
# NOT RUN {
arma.spec(ar = c(1, -.9), ma = .8)
# }

Run the code above in your browser using DataLab