I encountered a strange (at least to me) problem while calculating bond price using dynare. I hope someone can tell me what I am doing wrong.
- Code: Select all
rbn0_1 = 1/ (beta*mu(+1)/mu * (1/pi(+1)))
The code above is how I calculate the short-term nominal interest rate using the stochastic discounted factor and tomorrow's inflation. (nominal SDF = real SDF / tomorrow's inflation).
I also tried to define SDF explicitly in the dynare and tried the same thing,
- Code: Select all
sdf = beta*mu/mu(-1);
sdf_test = 1/ (sdf(+1) * (1/pi(+1));
I expected
- Code: Select all
rbn0_1
- Code: Select all
sdf_test
I really hope someone let me know what I have done wrong.
** I attached the full code.
Best,
Leo