Steady_state_model and diffuse_filter

Hi. When estimating the model without steady_state_model block I get an error “The steady state contains NaN or Inf”. Shouldn’t using diffuse_filter in estimation be enough to estimate non-stationary models? Or am I missing something here? Than you in advance for your help.
MVF_IMF_HR_check.mod (3.5 KB)
data_HR.xls (45 KB)

Before moving to estimation, make sure that the steady-command works.

Thank you for a quick response. I am not sure what do you mean by checking that steady works. Maybe I was not specific enough. I have non-stationary variables in the model so there is no well-defined steady state. Hence, I dont expect steady to work.

When I use steady_state_model block and I define arbitrary steady state everything works fine. I know that there were several similar questions here on the forum on this. My impression was that diffuse_filter option in estimation should “cancel” the steady state check option.

Even if your model does not admit a steady state, because of unit roots, the steady_state_model block or the steady state routine must return real numbers for all the endogenous variables, otherwise Dynare cannot evaluate the Jacobian of the dynamic model and perform the approximation. So You have to provide a fake steady state and use the nocheck option in steady, see the reference manual here.

Best,
Stéphane.

1 Like

Thank you for you response. So basically, with some models with unit roots it is enough to specify diffuse_filter option and with others one needs to specify steady_state_model block? For example, I have no trouble estimating HP-filter in Dynare using only diffuse_filter option in the estimation command (no fake steady state required for Dynare to do it).

I do not understand where the HP filter comes in here… Whatever is the model you try to estimate is, Dynare needs a steady state. If you do not provide an analytical steady state (which may be a fake one for some of the variables if there is no steady state) Dynare will use a general nonlinear solver to compute the steady state around which he will approximate the model. Obviously, Dynare will fail if there is no steady state (because of unit roots in the model). Even in the absence of such issues, relying on a general nonlinear solver is considered as bad practice, because even if the steady state exists, the general nonlinear solver may fail (also this approach is slower).

Best,
Stéphane.

I am using Dynare for a structural time series modeling so I mentioned HP-filter as an example of a non-stationary model that can be implemented in Dynare (there are actually two unit roots) and for which estimation goes through without specified analytical steady state. Maybe we are not understanding each other so here is a toy example: HP_test.mod (770 Bytes)
HP_basic_data.xls (23 KB)

I think you need to distinguish between a steady state not existing at all and the steady state not being unique. With a pure unit root, there are infinitely many steady states. With a unit root with drift, there is not steady state at all.
Your trend decomposition model contains a mixture of variables with a unit root and stationary variables with a unique steady state. You can easily verify that the default of 0 in Dynare is actually a valid steady state for all variables. That is why the code runs. If 0 is not a valid steady state, your steady_state_model should return one valid steady state for all variables`.

I see what you mean. I should have searched the forum more carefully because you have already discussed the same issue here: A nonstationary model for output gap with a const in drift
My apologies and thank you once again.