Arima

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 13

ACF – PACF:

Page 1 of 13
Page 2 of 13
AR Model:

Page 3 of 13
MA Model:

Page 4 of 13
ARMA Model:

Page 5 of 13
ARIMA:

Page 6 of 13
Pearson correlation coefficient

The Pearson correlation measures the strength of the linear relationship between
two variables. It has a value between -1 to 1, with a value of -1 meaning a total
negative linear correlation, 0 being no correlation, and + 1 meaning a total
positive correlation.

r = correlation coefficient

xi = values of the x-variable in a sample

x- = mean of the values of the x-variable

yi = values of the y-variable in a sample

y- = mean of the values of the y-variable

Page 7 of 13
What are ACF and PACF Plots in Time Series Analysis?

In time series analysis, ACF and PACF plots are two of the most important

tools for identifying the underlying structure of a time series.

 ACF plot shows the correlation of a time series with itself at different

lags.

 PACF plot shows the correlation of a time series with itself at

different lags, after removing the effects of the previous lags.

Autocorrelation Function (ACF)

 ACF plot is a graphical representation of the correlation of a time

series with itself at different lags.

 Correlation coefficient is a measure of how closely two variables are

related.

 A correlation coefficient of 1 indicates a perfect positive

relationship, while a correlation coefficient of -1 indicates a

perfect negative relationship, and 0 indicates no relationship

between the two variables.

Partial Autocorrelation Function (PACF)

 PACF plot is a graphical representation of the correlation of a time

series with itself at different lags, after removing the effects of the

previous lags.

 PACF plot can be used to identify the order of an MA model. The

order of an MA model is the number of lags that are included in the

model.

 PACF plot will show spikes at the lags that are included in the model.

Page 8 of 13
AR, MA and ARMA Models

AR Models

 An autoregressive (AR) model is a type of time series model that

uses the past values of a time series to predict future values.

 AR models are a popular choice for forecasting time series data

because they are relatively simple to understand and implement.

An AR model is typically written as:

y_t = c + \phi_1 y_{t-1} + \phi_2 y_{t-2} + ... + \phi_p y_{t-p} + \epsilon_t

where:
 yt is the value of the time series at time t
 c is the intercept term
 ϕ1,ϕ2,…,ϕp are the model coefficients
 ϵt is the error term

 The model coefficients, ϕ1,ϕ2,…,ϕp, are estimated using a variety of

methods, such as least squares estimation.

 Once the model coefficients are estimated, the model can be used to

predict future values of the time series.

 AR models are a versatile tool that can be used to forecast a wide

variety of time series data.

 The accuracy of an AR model will depend on the characteristics of

the time series data.

Advantages of using AR models:

 They are relatively simple to understand and implement.

 They can be used to forecast a wide variety of time series

data.

Page 9 of 13
 They are relatively efficient, meaning that they require a

relatively small amount of data to train.

Disadvantages of using AR models:

 They can be sensitive to outliers.

 They may not be accurate for time series data that is not

stationary.

 They may not be able to capture long-term trends.

MA Models

 A moving average (MA) model is a type of time series model that

uses the past errors of a time series to predict future values.

 MA models are a popular choice for forecasting time series data

because they are relatively simple to understand and implement.

An MA model is typically written as:

y_t = c + \theta_1 \epsilon_{t-1} + \theta_2 \epsilon_{t-2} + … + \theta_q \


epsilon_{t-q} + \epsilon_t

where:
 yt is the value of the time series at time t
 c is the intercept term
 θ1,θ2,…,θq are the model coefficients
 ϵt is the error term

 The model coefficients, θ1,θ2,…,θq, are estimated using a variety of

methods, such as least squares estimation.

 Once the model coefficients are estimated, the model can be used to

predict future values of the time series.

Page 10 of 13
 It is important to note that MA models are not always accurate.

 The accuracy of an MA model will depend on the characteristics of

the time series data.

Advantages of using MA models:

 They are relatively simple to understand and implement.

 They can be used to forecast a wide variety of time series

data.

 They are relatively efficient, meaning that they require a

relatively small amount of data to train.

Disadvantages of using MA models:

 They can be sensitive to outliers.

 They may not be accurate for time series data that is not

stationary.

 They may not be able to capture long-term trends.

MA models are often used in combination with AR models to create

ARMA models. ARMA models are more complex than AR or MA


models, but they can be more accurate for certain types of time series

data.

ARMA Models

 ARMA models are a combination of AR and MA models. The order of

an ARMA model is the sum of the order of the AR model and the

order of the MA model.

 It uses both the past values and the past errors of a time series to

predict future values.

Page 11 of 13
 ARMA models are a popular choice for forecasting time series data

because they are relatively simple to understand and implement,

and they can be more accurate than AR or MA models for certain

types of time series data.

Interpreting ACF and PACF Plots

The ACF and PACF plots can be used to identify the underlying structure of

a time series. The following are some general guidelines for interpreting

ACF and PACF plots:

 If the ACF plot shows spikes at the first few lags, then an

AR model may be appropriate.

 If the PACF plot shows spikes at the first few lags, then an

MA model may be appropriate.

 If the ACF and PACF plots both show spikes at the first few

lags, then an ARMA model may be appropriate.

It is important to note that the ACF and PACF plots are just a starting point

for identifying the underlying structure of a time series. The final model
should be chosen based on a combination of the ACF and PACF plots, as

well as other factors such as the Akaike Information Criterion (AIC) and the

Bayesian Information Criterion (BIC).

Page 12 of 13
Stationarity:

Page 13 of 13

You might also like