Plot Diagnostics for ARIMA Model

DESCRIPTION:
Plots diagnostics for an ARIMA model produced by the function arima.diag. The diagnostics include the autocorrelation function of the residuals, the standardized residuals, and the portmanteau goodness of fit test statistic.

USAGE:
arima.diag.plot(z, layout=<<see below>>, type="h", ...)

REQUIRED ARGUMENTS:
z:
a list as returned by the function arima.diag, including the components std.resid (or resid), acf.list, and/or gof.

OPTIONAL ARGUMENTS:
layout:
number of rows and columns of plots on a single page. The default puts all plots on one page, and depends on which components are in z.
type:
the type of residual plot. Choices in addition to the default are "l" and "p".
...:
additional parameters to be passed to the plot function for the plots of std.resid (or resid).

SIDE EFFECTS:
if std.resid is present, a plot of the standardized residuals will be produced. Otherwise, if resid is present, a plot of the raw residuals will be given. If acf.list is present, then acf.plot will be called to produce a plot of the autocorrelation function of the residuals with a 95% confidence band. If gof is present, then the p-values for the Portmanteau will be plotted.

DETAILS:
The plot for acf.list is always high density, and the plot for gof is always a point plot. The residual plot is controlled by the type argument.

REFERENCES:
Box, G. E. P. and Jenkins, G. M. (1976). Time Series Analysis: Forecasting and Control. Holden-Day, Oakland, Calif. Chapter 8.

SEE ALSO:
arima.diag , arima.filt .

EXAMPLES:
# compute and plot diagnostics for simulated AR(1) series
x <- arima.sim(model=list(ar=.9))
fit <- arima.mle(x,model=list(ar=.9))
diag <- arima.diag(fit)
# this is equivalent to
diag <- arima.diag(fit,plot=F)
arima.diag.plot(diag)