Endogenous priors and analytical derivation

Hello everyone,

From my understanding of the dsge_likelihood function, there is a conflict between the endogenous_prior and analytical_derivation options in the estimation command.

Specifically, the code does not compute the analytical derivative of the endogenous prior with respect to the parameter vector. As a result, both the analytical gradient and Hessian computed by the analytical_derivation option do not match the actual objective function, which includes the moment prior.

If this is an intended feature of the code, it might be worth clarifying it in the reference manual. If not, this may need a correction.

Thanks for reporting this bug. We will trigger an error in the future. See dsge_likelihood.m: flag analytical_derivation as incompatible with endogenous_prior (!2120) · Merge requests · Dynare / dynare · GitLab