Page 1 of 1

drawing mixture states of Kim, Shephard, and Chib (1998)

Posted: Mon Oct 19, 2015 3:50 pm
by tclark
Tom --

In comparing code I have for VARs with stochastic volatility to the code of other researchers that actually use different algorithms for drawing volatility, I have come to realize that my coding of the drawing of the mixture states used in the Kim, Shephard, and Chib (1998, RESTUD) algorithm is something of a bottleneck (this is the section of code in lines 590-618 and some dimensioning or setup that comes earlier in the .src file in the attached .zip) file. Are there ways you see to make the drawing of the mixture states more efficient, time-wise, than I have them? Any suggestions would be a great help. Thanks.

Todd

Re: drawing mixture states of Kim, Shephard, and Chib (1998)

Posted: Tue Dec 08, 2015 7:22 pm
by TomDoan
This would be my way to implement that. Other than doing the sqrt(...) just once, I'm not sure anything would significantly change the timing.

Re: drawing mixture states of Kim, Shephard, and Chib (1998)

Posted: Wed Dec 09, 2015 7:51 am
by tclark
Much, much appreciated, Tom. I will give your implementation a try. It is of course more elegant, even if it proves to be not a lot faster.