# A couple of questions about dynare

1. The expectation variable.
It is very interesting to look at the difference between the two equations:

lam-lam(+1)=r;
and lam-elam=r;
where elam=lam(+1);
If I use the first equation, the IRF starts from nonzero while if I use the second one, the IRF starts from zero. It is a tricky part but I love the pattern, so can someone explain the difference to me?

2. The difference between stoch_simul and simul
If I set periods=20 for both simulations, stoch_simul will give out exactly 20 numbers, but simul will give out about 23 numbers. Then how can I compare the two results. Are they the same, if they are, what do the extra numbers in result from simul mean?

3. Timing of shocks and decisions.
There are a lot of literatures talk about cases where more than one shocks, say, technology shock and monetary shock. Sometimes, they assume there is a sequence of decisions. Say, within one period, wage is determined before both shocks, price and output will determined after technology shock but before monetary shock. then monetary shock hits the economy. Should I split each period into several sub-period to do the issue or is there some routine in Dynare to handle this?

Best

[quote=“bigbigben”]1. The expectation variable.
It is very interesting to look at the difference between the two equations:

``````lam-lam(+1)=r;
and lam-elam=r;
``````

where elam=lam(+1);
If I use the first equation, the IRF starts from nonzero while if I use the second one, the IRF starts from zero. It is a tricky part but I love the pattern, so can someone explain the difference to me?
[/quote]

I’m sorry but IRF of which variable? in response to which shock ?

simul computes the numerical trajectories of a deterministic model. If there are enough periods in the simulation for the system to go back to equilibrium for all practical means, the accuracy of the solution can be very high.
The extra numbers are for initial and terminal values, before and after the simulation proper.
stoch_simul computes the local approximation of the decision and transition functions in a stochastic model. The accuracy is very rough as soon as one gets away from the steady state.
With the periods option, stoch_simul can compute a Monte-Carlo simulation of the model. You get then as many points as there were in the periods option.
You can’t compare the two procedures, or only for a model with zero variance on the stochastic shocks. But then, you can’t use the Monte-Carlo procedure.

This is really model dependent and there is no tool for it in Dynare. In several cases, you can recast these stories in the standard period by period timing of Dynare, but not always.

Best

Michel