Generate derivs wrt params when anaytic_derivation=1
parent
06ca265272
commit
00f526dbb7
|
@ -293,6 +293,11 @@ EstimationStatement::checkPass(ModFileStructure &mod_file_struct, WarningConsoli
|
|||
if (it != options_list.num_options.end() && it->second == "1")
|
||||
mod_file_struct.partial_information = true;
|
||||
|
||||
// Fill in mod_file_struct.estimation_analytic_derivation
|
||||
it = options_list.num_options.find("analytic_derivation");
|
||||
if (it != options_list.num_options.end() && it->second == "1")
|
||||
mod_file_struct.estimation_analytic_derivation = true;
|
||||
|
||||
it = options_list.num_options.find("dsge_var");
|
||||
if (it != options_list.num_options.end())
|
||||
// Ensure that irf_shocks & dsge_var have not both been passed
|
||||
|
|
|
@ -403,7 +403,7 @@ ModFile::computingPass(bool no_tmp_terms)
|
|||
}
|
||||
bool hessian = mod_file_struct.order_option >= 2 || mod_file_struct.identification_present;
|
||||
bool thirdDerivatives = mod_file_struct.order_option == 3;
|
||||
bool paramsDerivatives = mod_file_struct.identification_present;
|
||||
bool paramsDerivatives = mod_file_struct.identification_present || mod_file_struct.estimation_analytic_derivation;
|
||||
dynamic_model.computingPass(true, hessian, thirdDerivatives, paramsDerivatives, global_eval_context, no_tmp_terms, block, use_dll, byte_code);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -65,6 +65,8 @@ public:
|
|||
bool svar_identification_present;
|
||||
//! Whether an identification statement is present or the identification option of dynare_sensitivity statement is equal to one
|
||||
bool identification_present;
|
||||
//! Whether the option analytic_derivation is given to estimation
|
||||
bool estimation_analytic_derivation;
|
||||
//! Whether the option partial_information is given to stoch_simul/estimation/osr/ramsey_policy
|
||||
bool partial_information;
|
||||
//! Whether a shocks or mshocks block is present
|
||||
|
|
Loading…
Reference in New Issue