Dynamic conditional correlation
Multivariate GARCH models, which are linear in squares and cross products of the data, are generally used to estimate the correlations changing with time. Now this can be estimated using dynamic conditional correlation (DCC), which is a combination of a univariate GARCH model and parsimonious parametric models for the correlation. It has been observed that they perform well in a variety of situations. This method has the flexibility of univariate GARCH and does not have the complexity of multivariate GARCH.
Now let us see how to execute DCC in R.
First we need to install and load the packages rmgarch
and PerformanceAnalytics
. This can be done by executing the following code:
install.packages("rmgarch") install.packages("PerformanceAnalytics") library(rmgarch) library(PerformanceAnalytics)
Now let us consider returns of the last year for the S&P 500
and DJI indexes and try to get DCC for these returns.
Now let us set the specification for DCC by executing...