Drawing from non-normal distributions(uniform)in simulation

Hi ,

I was trying to simulate (not estimate) a model with a shock which is not have normal distributions. Particularly I’d be interested in specifying that my shock is uniformly distributed(-1,1). (I’m also interested in truncated normals.)

I would like to figure out the best way to specify how to do this in the shocks; I use Dynar4.4.3.

Thanks for the help,

PS: I saw the [Drawing from non-normal distributions in model simulation) but unfortunately it is just for [0 1] and also I could not find that line in the matlab file simult.m.

At first order, you have to change line 83 of the simult.m in the Dynare/matlab folder, which reads

DynareResults.exo_simul(:,i_exo_var) = randn(nxs,DynareOptions.periods)'*chol_S;
to something like

DynareResults.exo_simul(:,i_exo_var) = 2*(rand(nxs,DynareOptions.periods)-0.5);
Due to certainty equivalence, it does not matter that the shocks you are drawing now have a different standard deviation than is used for computing the decision rules. At higher order, this approach would be wrong.