CC-VARMA model

Discussions of ARCH, GARCH, and related models
econo
Posts: 32
Joined: Fri Sep 05, 2014 9:16 am

CC-VARMA model

Unread post by econo »

Dear Friends;
I am trying to run mGARCH models for log-return oil prices & H index. (bi-variate) :
So I run this code in RATS 8.0 :

Code: Select all

open data Y1_O_A.xls
data(format=xls,org=columns) / O A
compute gstart=2,gend=2000
garch(p=1,q=1,mv=CC,variance=varma,pmethod=simplex,piters=5,hmatrices=hh, rvectors=rv) gstart gend O A
and I got this results:

Code: Select all

MV-GARCH, CC with VARMA Variances - Estimation by BFGS
Log Likelihood                     12223.0018

    Variable                        Coeff      Std Error      T-Stat      Signif
************************************************************************************
1.  Mean(1)                       3.3466e-004  4.0690e-004      0.82246  0.41081547
2.  Mean(2)                       6.4086e-004  2.7855e-004      2.30071  0.02140775
3.  C(1)                          3.6206e-006  1.6079e-006      2.25172  0.02434008
4.  C(2)                         -1.9890e-008  4.4641e-007     -0.04455  0.96446242
5.  A(1,1)                             0.0522   8.9554e-003      5.83329  0.00000001
6.  A(1,2)                       -6.3090e-003       0.0113     -0.55932  0.57594292
7.  A(2,1)                       -9.6068e-003  6.7144e-003     -1.43077  0.15249594
8.  A(2,2)                             0.0520  9.7580e-003      5.32894  0.00000010
9.  B(1,1)                             0.9312       0.0141     66.11622  0.00000000
10. B(1,2)                             0.0969       0.0710      1.36506  0.17223538
11. B(2,1)                             0.0952       0.0439      2.16951  0.03004371
12. B(2,2)                             0.9355       0.0119     78.88939  0.00000000
13. R(2,1)                             0.1271       0.0204      6.22132  0.00000000
Now, I have these questions and appreciate if somebody can help.

1. the parameters are a little bit different from the original paper:
Here I have A , B matrices which I assume are alpha & betas in table 4 of paper. (then how can calculate alpha+beta ? is it A(1,1)+B(1,1) and A(2,2)+B(2,2) ??

2.Then what is R(2,1) ?
3.is Mean (1) the same as AR ?
4.is mean (2) the same as MA?

thanks in advance.
Last edited by econo on Fri May 22, 2015 2:28 am, edited 3 times in total.
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: VARMA GARCH Model

Unread post by TomDoan »

omid_ie wrote:Dear Friends;
I am trying to run VARMA-GARCH models for log-return oil prices & HS300 index. (bi-variate) according to table 4 of Prof. McAleer and Prof. Chang paper:
http://ideas.repec.org/p/kyo/wpaper/743.html
They're doing ARMA mean models combined with McAleer CC-VARMA-GARCH. You're not doing the ARMA mean model. The other questions are answered in the other post.

They note that they did this with RATS 6.2. Have you asked them for the code?
econo
Posts: 32
Joined: Fri Sep 05, 2014 9:16 am

Re: CC-VARMA model

Unread post by econo »

This is prof. McAleer answer :
"As an alternative, if you want to estimate VARMA-GARCH and VARMA-AGARCH using RATS, set MV = CC, VARIANCES = VARMA for VARMA-GARCH, and add ASYMMETRIC for VARMA-AGARCH."

I think, they are using ARMA (1,1) mean , VARMA GARCH. Then How can I adjust rats code with this?
Last edited by econo on Mon Jan 19, 2015 4:37 am, edited 1 time in total.
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: VARMA GARCH Model

Unread post by TomDoan »

I would recommend not trying to do the ARMA(1,1) for the mean. The constant alone seems to be sufficient. Run the simpler model and do the diagnostics before doing a more complicated mean model that (at least for their data) seems to be unnecessary.
econo
Posts: 32
Joined: Fri Sep 05, 2014 9:16 am

CC-VARMA model

Unread post by econo »

TomDoan wrote: The constant alone seems to be sufficient. Run the simpler model and do the diagnostics before doing a more complicated mean model that (at least for their data) seems to be unnecessary.
Thanks a lot.
the interpretation is next problem:
you said the constant alone seems to be sufficient:
but the Mean(1) is not sufficient,the same for C(2).

Code: Select all

1.Mean(1)                       3.3466e-004  4.0690e-004      0.82246  0.41081547
2.  Mean(2)                       6.4086e-004  2.7855e-004      2.30071  0.02140775
3.  C(1)                          3.6206e-006  1.6079e-006      2.25172  0.02434008
4.  C(2)                         -1.9890e-008  4.4641e-007     -0.04455  0.96446242
13. R(2,1)                             0.1271       0.0204      6.22132  0.00000000
so can you explain it more?
Last edited by econo on Mon Jan 19, 2015 4:37 am, edited 1 time in total.
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: VARMA GARCH Model

Unread post by TomDoan »

There's no a priori reason to expect that the mean will be significant.

The c can be insignificant if the model (or at least that equation) is borderline IGARCH---see if b(2) and a(2) add up to very close to 1.

BTW, multiply those series by 100 to get the scale up on the mean and C coefficients.
econo
Posts: 32
Joined: Fri Sep 05, 2014 9:16 am

CC-VARMA model

Unread post by econo »

Ok , this is results where the variables are multiplied by 100

Code: Select all

Variable                        Coeff      Std Error      T-Stat      Signif
************************************************************************************
1.  Mean(1)                       0.033465914  0.040926943      0.81770  0.41352917
2.  Mean(2)                       0.064086122  0.028401883      2.25640  0.02404534
3.  C(1)                          0.036206243  0.014510638      2.49515  0.01259033
4.  C(2)                         -0.000199065  0.004717736     -0.04220  0.96634316
5.  A(1,1)                        0.052239319  0.009027327      5.78680  0.00000001
6.  A(1,2)                       -0.006309001  0.011013540     -0.57284  0.56675276
7.  A(2,1)                       -0.009606734  0.006542144     -1.46844  0.14198522
8.  A(2,2)                        0.051999486  0.009843136      5.28282  0.00000013
9.  B(1,1)                        0.931221690  0.013783808     67.55910  0.00000000
10. B(1,2)                        0.096910622  0.072215028      1.34197  0.17960473
11. B(2,1)                        0.095163376  0.046349974      2.05315  0.04005818
12. B(2,2)                        0.935480030  0.012003656     77.93292  0.00000000
13. R(2,1)                        0.127138818  0.021361871      5.95167  0.00000000

by " if b(2) and a(2) add up to very close to 1"
do you mean :
A(1,1)+B(1,1) = 0.983461009
A(2,2) + B(2,2) =0.987479516
??
Last edited by econo on Mon Jan 19, 2015 4:37 am, edited 1 time in total.
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: CC-VARMA model

Unread post by TomDoan »

Note that I created a new thread because the thread you added on to was for a VARMA mean model, not a CC-VARMA model. The two are completely different.

With the VARMA model for the individual variances, it's possible to have one of the constants effectively zero, because the dynamics allow for a non-zero mean coming from the other variable. (You can solve out for the unconditional variance to verify that). That's not true for a regular CC model where a zero C only makes sense for an IGARCH.
econo
Posts: 32
Joined: Fri Sep 05, 2014 9:16 am

Re: CC-VARMA model

Unread post by econo »

Dear Tom;

based on our discussion, I want to implement VARMA GARCH (Mc aleer) model. so I used this code:

Code: Select all

open data LogReturn.xls
data(format=xls,org=columns) / O S
compute gstart=2,gend=2354
garch(p=1,q=1,mv=CC,variance=varma,pmethod=simplex,piters=5,hmatrices=Varmah, MVHSERIES=VarmaHmatrix, rvectors=Varmarv,STDRESIDS=Varmaeta ) gstart gend O S
set ccorr2 %regstart() %regend() = %cvtocorr(Varmah)(1,2)
open copy Varma-condcor.xls
copy(data,format=xls,org=columns)  /ccorr2
open copy VarmaHmatrix.xls
copy(data,format=xls,org=columns)  /VarmaHmatrix

open copy VarmaETA.xls
copy(data,format=xls,org=columns)  /Varmaeta
the code works properly and ccorr2, gives constant result.

also this is the result of model:

Code: Select all

    Variable                        Coeff      Std Error      T-Stat      Signif
************************************************************************************
1.  Mean(O)                    4.4539e-004  2.2439e-004      1.98484  0.04716255
2.  Mean(S)                 2.7720e-004  3.7445e-004      0.74030  0.45911921

3.  C(1)                          1.0030e-006  4.4469e-007      2.25547  0.02410384
4.  C(2)                          2.0619e-006  8.4266e-007      2.44685  0.01441117
5.  A(1,1)                             0.0545  8.9269e-003      6.10448  0.00000000
6.  A(1,2)                            -0.0182  6.2230e-003     -2.92654  0.00342751
7.  A(2,1)                        6.1094e-003  8.9175e-003      0.68510  0.49327841
8.  A(2,2)                             0.0450  7.6579e-003      5.87076  0.00000000
9.  B(1,1)                             0.9399       0.0101     92.90224  0.00000000
10. B(1,2)                             0.0389       0.0371      1.04799  0.29464551
11. B(2,1)                             0.0444       0.0457      0.97121  0.33144291
12. B(2,2)                             0.9436       0.0103     91.47552  0.00000000
13. R(2,1)                             0.1398       0.0201      6.96538  0.00000000

Now, as I will use the VarmaETA for other models. Just want to make sure that this is correct?
also, if I am not mistaken the varmaETA will be is a sequence of i.i.d. random vectors, with zero mean and
covariance (gamma). Not Normally distributed??
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: CC-VARMA model

Unread post by TomDoan »

omid_ie wrote:Now, as I will use the VarmaETA for other models. Just want to make sure that this is correct?
also, if I am not mistaken the varmaETA will be is a sequence of i.i.d. random vectors, with zero mean and
covariance (gamma). Not Normally distributed??
i.i.d. is overstating it. They are (if the underlying model is correct), uncorrelated across time and having an identity covariance matrix. If the residuals are conditionally Normal, then the standardized residuals will be as well.
econo
Posts: 32
Joined: Fri Sep 05, 2014 9:16 am

Re: CC-VARMA model

Unread post by econo »

Now, in this model ( Mcaleer CC-varma=variance) if I want to change mean equation to VAR(1) or VARMA mean model, how can I do it?

Thanks in advance
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: CC-VARMA model

Unread post by TomDoan »

The mean model is specified the same way regardless of the form of the GARCH model. See Section 9.4.5 of the (v9) User's Guide. However, I would recommend testing the residuals from the simpler model first. If they pass a test for lack of serial correlation, then there is nothing really to be gained by going to a VAR, and a VARMA model would be almost impossible to fit due to cancellation.

You might want to look into getting the ARCH/GARCH course.
econo
Posts: 32
Joined: Fri Sep 05, 2014 9:16 am

Re: CC-VARMA model

Unread post by econo »

Can I define VAR(1), something like this?

Code: Select all

system(model=var)
variables O S
lags 1
det constant u(1){1} u(2){1}
end(system)
*
do i=1,2
   set u(i) = 0.0
end do i


garch(p=1,q=1,model=var,mv=CC,variance=varma,pmethod=simplex,piters=5,hmatrices=Varmah, MVHSERIES=VarmaHmatrix, rvectors=Varmarv,STDRESIDS=Varmaeta ) gstart gend O S
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: CC-VARMA model

Unread post by TomDoan »

For a VAR(1), you just want:

det constant

You're about halfway towards the setup for a VARMA, which again, I wouldn't recommend. If you find serial correlation in the standardized residuals, start with the simpler VAR. VARMA (mean models) have all kinds of numerical issues; VAR's don't.
econo
Posts: 32
Joined: Fri Sep 05, 2014 9:16 am

Re: CC-VARMA model

Unread post by econo »

Dear Tom;

I just really want to run VAR(1) with variance following : CCC- VARMA (Mcaleer 2003).

The thing is I dont have just 2 indices it is 31 pairs!!

I will do the test for residuals but as there 31 pairs of data, so still I need to check VAR(1)
so please help me to finish this. thanx a lot.
Post Reply