Good morning,
I hope that this is the right forum to ask this question. If not, please accept my apologies, and feel free to move this thread to a different forum as appropriate.
My question concerns the discretionary_policy function. In the code I’m working with, this is called as
discretionary_policy(
instruments = (int),
planner_discount = 1,
irf = 100,
nograph,
noprint
);
causing Dynare to (correctly) remark that with a unity discount factor, the unconditional expected welfare will be infinite (evaluate_planner_objective: the planner discount factor is not strictly smaller than 1. Unconditional welfare will not be finite.)
This is actually no concern (interest lies on the IRFs, not the unconditional welfare), but the call to discretionary_policy is happening in a tight loop that runs thousands of times, and I’m wondering whether there isn’t a way to suppress this message. Looking at evaluate_planner_objective.m, there appears to be no flag for this.
I tried wrapping the call to discretionary_policy in MATLAB’s built-in evalc() to redirect console output to a variable, but the Dynare preprocessor then doesn’t replace the call to discretionary_policy anymore (sensibly, as a general matter, though I’d like for it to happen in this particular case).
Is there a way to suppress these messages, or will I have to live with them? I’ve found nothing on either these forums or Google.
Alternatively, is my assumption that the unity discount factor is truly harmless because I don’t care about unconditional welfare correct, or could this be a problem even if I only care about the IRFs?
Thank you very much for your help!