AR

AR stands for autoregressive model. Its basic concept is that future values depend on past values and they are estimated using a weighted average of the past values. The order of the AR model can be estimated by plotting the autocorrelation function and partial autocorrelation function of the series. In time series autocorrelation function measures correlation between series and it's lagged values. Whereas partial autocorrelation function measures correlation of a time series with its own lagged values, controlling for the values of the time series at all shorter lags. So first let us plot the acf and pcf of the series. Let us first plot the acf plot by executing the following code:

> PriceData<-ts(StockData$Adj.Close, frequency = 5) > acf(PriceData, ...

Get Learning Quantitative Finance with R now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.