Page 1 of 1

How to see the values of Largrange multiplier for Ramsey

PostPosted: Fri Dec 16, 2016 11:37 pm
by nkhesicheng
Hi! I am working on a Ramsey problem. I input the results of competitive equilibrium and set the Ramsey policy. I would like to see the value of largrange multiplier for different periods just like other endogenous variables but I can only find the steady state values in oo. Is there anybody who can tell me how to check these values? Thank you very much.

Re: How to see the values of Largrange multiplier for Ramsey

PostPosted: Sun Dec 18, 2016 8:23 pm
by jpfeifer
Code: Select all
oo_.endo_simul
should store all simulated variables, including the Lagrange multipliers.

Re: How to see the values of Largrange multiplier for Ramsey

PostPosted: Sun Dec 18, 2016 10:33 pm
by nkhesicheng
jpfeifer wrote:
Code: Select all
oo_.endo_simul
should store all simulated variables, including the Lagrange multipliers.

Thank you for your help but I am solving a stochastic problem so the oo_.endo_simul is vacant. I check the oo_.irfs and find that it save all the other endogenous variables except lagrange multipliers established by ramsey_policy. But I can still see lagrange multipliers such as MULT_1's value in oo_.steady_state. Is this value dropped by the program? Thank you.

Re: How to see the values of Largrange multiplier for Ramsey

PostPosted: Mon Dec 19, 2016 6:52 am
by jpfeifer
Code: Select all
oo_.endo_names
will not be vacant in stochastic simulations if you specify the
Code: Select all
periods
-option. But you seem to be interested in IRFs, not simulations. This is more tricky and we are working on it: https://github.com/DynareTeam/dynare/issues/1355
What you can do for now is define your own
Code: Select all
var_list_
and then call
Code: Select all
ramsey_policy
yourself. To do this, run the regular mod-file including the standard Ramsey command. This will set up everything. Then use
Code: Select all
verbatim;
var_list_=char('MULT_1');
ramsey_policy(var_list_);
end;

where
Code: Select all
var_list_
is a character array specifying the variables of
Code: Select all
M_.endo_names
you want to display (here: the first multiplier).

Re: How to see the values of Largrange multiplier for Ramsey

PostPosted: Mon Dec 19, 2016 5:17 pm
by nkhesicheng
jpfeifer wrote:
Code: Select all
oo_.endo_names
will not be vacant in stochastic simulations if you specify the
Code: Select all
periods
-option. But you seem to be interested in IRFs, not simulations. This is more tricky and we are working on it: https://github.com/DynareTeam/dynare/issues/1355
What you can do for now is define your own
Code: Select all
var_list_
and then call
Code: Select all
ramsey_policy
yourself. To do this, run the regular mod-file including the standard Ramsey command. This will set up everything. Then use
Code: Select all
verbatim;
var_list_=char('MULT_1');
ramsey_policy(var_list_);
end;

where
Code: Select all
var_list_
is a character array specifying the variables of
Code: Select all
M_.endo_names
you want to display (here: the first multiplier).

Thank you very much. It helps me a lot.

Re: How to see the values of Largrange multiplier for Ramsey

PostPosted: Tue Dec 27, 2016 1:19 pm
by jpfeifer
Starting with tomorrow, the preprocessor will also accept auxiliary variables in the variable list of the Ramsey command, see https://github.com/DynareTeam/dynare/issues/1355