4
$\begingroup$

I'm calculating DCC between S&P500 and US 10-year bond index in R.

However the results are in the unexpected sign. For example, as published by many, DCC between S&P500 and 10-year bond index is positive in 1990s and became negative for a while in 1997 (e.g. Chen(2009) on page 43 http://eprints.lse.ac.uk/29306/1/Regime_Switching_in_Volatilities.pdf), but I got opposite results.

Here is my code, is there anything wrong?

    # 1. Fit DCC
# First GARCH Specs.. GARCH(1,1)
garch11.spec = ugarchspec(mean.model = list(armaOrder = c(1,1)), 
                          variance.model = list(garchOrder = c(1,1), 
                                                model = "sGARCH"), distribution.model = "std")
# dcc specification - GARCH(1,1) for conditional correlations
dcc.garch11.spec = dccspec(uspec = multispec( replicate(2, garch11.spec) ), dccOrder = c(1,1), distribution = "mvt")

# SD 
garch.fit = ugarchfit(garch11.spec, data = STOCK, fit.control=list(scale=TRUE))
print(garch.fit)

garch.fit = ugarchfit(garch11.spec, data = BOND, fit.control=list(scale=TRUE))
print(garch.fit)

#DCC - STOCK&BOND
dcc_data<-data.frame(STOCK,BOND)
dcc.fit = dccfit(dcc.garch11.spec, data = dcc_data, fit.control=list(scale=TRUE))
print(dcc.fit)
r1=rcor(dcc.fit, type="cor")
r1.z=zoo(r1[1,2,], order.by=DATA$Date[-1])
dcc_stock_bond<-data.frame(r1.z)
print(dcc_stock_bond)

Edit: please note that I was using bond yield rather than bond index. Having used bond index, I got the expected DCC results. Problem solved.

$\endgroup$
  • $\begingroup$ Do the other studies also assume the same conditional mean and conditional variance dynamics, i.e. ARMA(1,1)-GARCH(1,1)? I suppose ARMA(1,1) could be omitted in favour of just a constant, probably then your model would yield the expected signs of the fitted conditional correlations. $\endgroup$ – Richard Hardy Nov 20 '16 at 14:38
  • $\begingroup$ Thanks @RichardHardy ! More or less in other studies. EGARCH is also considered. I tried ARMA(0,0)-GARCH(1,1) and results are very similar, still unexpected sign but slightly more volatile. $\endgroup$ – sileli Nov 20 '16 at 15:10
  • $\begingroup$ What if you fit the model fo subsamples of your data? Vanilla DCC is a bit inflexible, so I would not expect that it would produce a wide range of correlation dynamics over time for a given time series. $\endgroup$ – Richard Hardy Nov 20 '16 at 16:09
  • $\begingroup$ When you say a similar pattern, do you mean similar to your estimated DCC model or to the paper you are citing? $\endgroup$ – Richard Hardy Nov 21 '16 at 6:22
  • $\begingroup$ Similar to estimated DCC model as plotted. $\endgroup$ – sileli Nov 21 '16 at 9:40
3
$\begingroup$

Do the other studies also assume the same conditional mean and conditional variance dynamics of the univarate models, i.e. ARMA(1,1)-GARCH(1,1)? I suppose ARMA(1,1) could be omitted in favour of just a constant.
[Apparently this does not generate the desired result.]

What if you fit the model fo subsamples of your data? Vanilla DCC is a bit inflexible, so I would not expect that it would produce a wide range of correlation dynamics over time for a given time series. There is a function dccroll for rolling estimation and forecasting, perhaps it could be useful.

Finally, after having estimated the univariate models you can skip the DCC step and instead estimate correlations in rolling windows. That is another way of assessing how the correlation develops over time.

$\endgroup$
  • $\begingroup$ Thanks! Interestingly, rolling correlation (30 days) shows a similar pattern which is different from published studies. I also ran it in stata and results from stata is the same with published ones. $\endgroup$ – sileli Nov 20 '16 at 20:32
  • $\begingroup$ @Sile_Li, This sounds crazy :) How can R produce something different than Stata if the model specification is the same? I suppose the model specification should differ, probably there are some fine details you are missing. I don't know Stata well enough to comment on that aspect. $\endgroup$ – Richard Hardy Nov 21 '16 at 6:20
  • $\begingroup$ Hi @Richard, yes quite confusing. I attached a plot of results from DCC from R and simple rolling correlation, which are similar, but different from published ones, e.g. Gusset & Zimmermann (2015) on page 3 bit.ly/2fdZRV8). $\endgroup$ – sileli Nov 21 '16 at 9:38
  • $\begingroup$ @Sile_Li, I do not have the time to read the paper (even though I am curious what is going on), but can it be that G&Z (2015) did not describe their procedure in sufficient detail so that some step is missing in the analysis? Do they provide their code and data on their website or somewhere? $\endgroup$ – Richard Hardy Nov 21 '16 at 13:52
  • 2
    $\begingroup$ Well, since you put the effort in posting it and I put the effort in answering it, we might keep it for the record. While your question is no longer interesting to you, perhaps my answer can be useful for future visitors as it is quite generic. You could edit the post by adding a line at the end saying something like "Edit: I was using bond yield rather than bond index. Having used bond index, I got the expected DCC results. Problem solved." What do you think about that? $\endgroup$ – Richard Hardy Feb 22 '17 at 15:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.