Page 1 of 1

Problem with Time Varying VAR

Posted: Mon Mar 28, 2016 3:54 am
by fructuoso
Dear all,

I have been writing a Time Varying VAR code in RATS by using Carter Kohn algorithm, but I am getting a really bad result from it. When I do the first step of the algorithm, drawing BT from a normal distribution, I use %modelsetcoeffs to put BT into a VAR in order to check the stability, I get that the largest root in the model is between 30 and 60, and it should not be higher tan one. I have been looking for an explanation, and I found that the Cholesky decomposition of the conditional variance necessary for drawing BT is causing the problem.

I think that the easiest route to solve my problem is using the Durbin Koopman algorithm instead, but I have not been able to find an example of such code in RATS -I know that it is used in DLM, but I would like to see how it works-. Please, if any of you have it, can you provide me with such code? Or any other idea to solve the problem?

Kind regards,

fructuoso

Re: Problem with Time Varying VAR

Posted: Mon Mar 28, 2016 7:38 am
by TomDoan
You just set up the state-space model and use TYPE=CSIMULATE. See, for example, the LUTKP637.rpf example in the Lutkepohl examples. You can find other examples by using Help-Find in Files and looking for TYPE=CSIMULATE.

Re: Problem with Time Varying VAR

Posted: Mon Mar 28, 2016 10:40 am
by fructuoso
Dear Tom,

Thank you very much for your answer. I understand, by the Lutkepohl example, that I should estimate the TVAR equation by equation using DLM. Am I right?

Best regards,

Fructuoso

Re: Problem with Time Varying VAR

Posted: Tue Mar 29, 2016 12:50 pm
by TomDoan
That's just an example. You can apply DLM to a full system if you want.