Can someone tell me to draw a truncated prior?
I want to write the prior for parameter Xini, with mean = -1 and std error = 0.1, normal distribution, but Xini can have only negative values.
Is prior code like below correct?
Xini, -1, -inf, 0, normal_pdf,-1, 0.1;
Thanks in advance…
For the moment, Dynare does not support truncated priors except during mode-finding. Do you use a steady state file?
Yes, I use a steady state file.
In that case, it is easiest to implement the truncation in that file. Check whether the bound is satisfied and if not, set the error code and return:
if Xini>0 % parameter violates restriction params=M_.params; check=1; %set failure indicator return; %return without updating steady states end