Fit a univariate AR model by Yule-Walker method, Least squares (Householder) method or PARCOR method.
arfit(y, lag = NULL, method = 1, plot = TRUE, …)
a univariate time series.
highest order of AR model. Default is \(2 \sqrt{n}\), where \(n\) is the length of the time series y.
y
estimation procedure.
logical. If TRUE (default), PARCOR, AIC and power spectrum are plotted.
TRUE
further arguments to be passed to plot.arfit.
plot.arfit
An object of class "arfit", which is a list with the following elements:
"arfit"
innovation variance.
order of minimum AIC.
AIC.
AR coefficients of the best model.
PARCOR.
power spectrum (in log scale).
the name of the univariate time series y.
Kitagawa, G. (2010) Introduction to Time Series Modeling. Chapman & Hall/CRC.
# NOT RUN { # Sun spot number data data(Sunspot) arfit(log10(Sunspot), 20) # BLSALLFOOD data data(BLSALLFOOD) arfit(BLSALLFOOD) # }
Run the code above in your browser using DataCamp Workspace