Optimal simple rule

Dear Prof. Pfeifer,

I would like to find the value of a parameter (phiP) which minimizes the variance of consumption using osr. However, Dynare is unable to find a solution. I wondered if there was something I may be doing wrong? When I make some minor changes to the osr weights, I get astronomical values of phiP which I would like to lie between -1 and 1.

Can I also ask whether there is some way I could find the optimal value of this parameter which maximizes intertemporal utility?

Please find attached a zip file. The file to run is the run.m file which should in turn run cycle_irf.

Many thanks
Forum.zip (1.26 MB)

  1. What do you mean with
Dynare is unable to find a solution

When I run the code with the unstable version, I get

which is a solution

  1. It is not unheard of that optimal parameters may be infinity (essentially full stabilization). In those cases, people often restrict the parameter range. In the unstable version, you can use

osr_param_bounds; phiP, -1, 1; end;

  1. What do you mean with

You want a welfare function that is maximized using that parameter?

Many thanks Prof. Pfeifer.

I think that was my problem, I used the stable version. I will try with the unstable version and I am sure all should be fine then. Thanks for letting me know about the bounds as well. I wasn’t aware of that feature.

With regards to 3), I meant is there a way to find the value of the parameter phiP which maximizes welfare (I already have a welfare function)?

Regarding 3, that is not available as a boxed solution. The problem is that this only makes sense in a model with order=2, because otherwise stochastics is not going to affect the mean of welfare. But it can be easily implemented in Dynare if necessary