Page 1 of 1

Why isn't 'bootstrp' working?

PostPosted: Sun Dec 02, 2012 2:22 pm
by yvette-hyq
I have written some codes to run DSGE model twice in Dynare and then do some bootstrapping.

Since I installed the new version 4.3.0, I noticed that the 'bootstrp' command in matlab give me the same bootstrapping result all the time.

I think it is due to some of functions in Dynare are intervening with original matlab commands. But I have no idea how to find them out and whether I could delete them without causing further problems.

Has anyone come across this problem before? and find out what are the causes? Please help me!!!

Thanks a lot.

Re: Why isn't 'bootstrp' working?

PostPosted: Sun Dec 02, 2012 5:07 pm
by yvette-hyq
I tried 4.1.2 version, 4.2.4 version and 4.3.1 version. Only 4.1.2 version would give me changing bootstrapping result.

I also rewrite the code using randi(n,n,1) to generate single bootstrapped indexes. It only works under 4.1.2 version as well.

is there a bug in newer version of Dynare?

Thanks in advance.

Yvette

Re: Why isn't 'bootstrp' working?

PostPosted: Wed Jan 09, 2013 5:02 pm
by SébastienVillemot
There is no "bootstrp" command in Dynare, so I don't really know what you are talking about.

However, what may be relevant to your problem is the fact that recent versions of Dynare are deliberately resetting the random number generation at every run. The idea is to have identical estimation results across runs of Dynare. The drawback is that people who were used to run Dynare several times to get different stochastic simulation results have to adapt their code. You can use the "set_dynare_seed" command to use a different seed for the random number generator across your runs of Dynare.

Re: Why isn't 'bootstrp' working?

PostPosted: Thu Jan 10, 2013 11:00 am
by jpfeifer
You could try to define a new randon number stream that you use for bootstrapping. That way, you would not use the default stream that is reset by Dynare for reproducability of results.