finalize svar_global_identification_check
parent
33fe47d367
commit
203ddeba3d
|
@ -1627,6 +1627,8 @@ SvarIdentificationStatement::getMaxLag() const
|
|||
void
|
||||
SvarIdentificationStatement::checkPass(ModFileStructure &mod_file_struct, WarningConsolidation &warnings)
|
||||
{
|
||||
// no equations OK with Svar Identification
|
||||
mod_file_struct.bvar_present = true;
|
||||
if (!mod_file_struct.svar_identification_present)
|
||||
mod_file_struct.svar_identification_present = true;
|
||||
else
|
||||
|
@ -1704,6 +1706,7 @@ SvarIdentificationStatement::writeOutput(ostream &output, const string &basename
|
|||
it->value->writeOutput(output);
|
||||
output << ";" << endl;
|
||||
}
|
||||
output << "options_.ms.nlags = " << r << ";" << endl;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2010,6 +2013,16 @@ SvarStatement::writeOutput(ostream &output, const string &basename, bool minimal
|
|||
output << "'ALL';" << endl;
|
||||
}
|
||||
|
||||
SvarGlobalIdentificationCheckStatement::SvarGlobalIdentificationCheckStatement(void)
|
||||
{
|
||||
}
|
||||
|
||||
void
|
||||
SvarGlobalIdentificationCheckStatement::writeOutput(ostream &output, const string &basename, bool minimal_workspace) const
|
||||
{
|
||||
output << "svar_global_identification_check(options_);" << std::endl;
|
||||
}
|
||||
|
||||
SetTimeStatement::SetTimeStatement(const OptionsList &options_list_arg) :
|
||||
options_list(options_list_arg)
|
||||
{
|
||||
|
|
|
@ -640,6 +640,13 @@ public:
|
|||
virtual void writeOutput(ostream &output, const string &basename, bool minimal_workspace) const;
|
||||
};
|
||||
|
||||
class SvarGlobalIdentificationCheckStatement : public Statement
|
||||
{
|
||||
public:
|
||||
SvarGlobalIdentificationCheckStatement();
|
||||
virtual void writeOutput(ostream &output, const string &basename, bool minimal_workspace) const;
|
||||
};
|
||||
|
||||
class SetTimeStatement : public Statement
|
||||
{
|
||||
private:
|
||||
|
|
|
@ -157,7 +157,7 @@ class ParsingDriver;
|
|||
%token MS_ESTIMATION MS_SIMULATION MS_COMPUTE_MDD MS_COMPUTE_PROBABILITIES MS_FORECAST
|
||||
%token SVAR_IDENTIFICATION EQUATION EXCLUSION LAG UPPER_CHOLESKY LOWER_CHOLESKY MONTHLY QUARTERLY
|
||||
%token MARKOV_SWITCHING CHAIN DURATION NUMBER_OF_REGIMES NUMBER_OF_LAGS
|
||||
%token SVAR COEFF COEFFICIENTS VARIANCES CONSTANTS EQUATIONS
|
||||
%token SVAR SVAR_GLOBAL_IDENTIFICATION_CHECK COEFF COEFFICIENTS VARIANCES CONSTANTS EQUATIONS
|
||||
%token EXTERNAL_FUNCTION EXT_FUNC_NAME EXT_FUNC_NARGS FIRST_DERIV_PROVIDED SECOND_DERIV_PROVIDED
|
||||
%token SELECTED_VARIABLES_ONLY COVA_COMPUTE SIMULATION_FILE_TAG FILE_TAG
|
||||
%token NO_ERROR_BANDS ERROR_BAND_PERCENTILES SHOCKS_PER_PARAMETER NO_CREATE_INIT
|
||||
|
@ -258,6 +258,7 @@ statement : parameters
|
|||
| conditional_forecast_paths
|
||||
| plot_conditional_forecast
|
||||
| svar_identification
|
||||
| svar_global_identification_check
|
||||
| markov_switching
|
||||
| svar
|
||||
| external_function
|
||||
|
@ -850,6 +851,10 @@ restriction_elem_expression : COEFF '(' symbol COMMA INT_NUMBER ')'
|
|||
{ driver.add_positive_restriction_element($1,$5,$7);}
|
||||
;
|
||||
|
||||
svar_global_identification_check: SVAR_GLOBAL_IDENTIFICATION_CHECK ';'
|
||||
{ driver.add_svar_global_identification_check(); }
|
||||
;
|
||||
|
||||
markov_switching : MARKOV_SWITCHING '(' ms_options_list ')' ';'
|
||||
{ driver.markov_switching(); }
|
||||
;
|
||||
|
|
|
@ -163,6 +163,7 @@ DATE -?[0-9]+([YyAa]|[Mm]([1-9]|1[0-2])|[Qq][1-4]|[Ww]([1-9]{1}|[1-4][0-9]|5[0-2
|
|||
|
||||
<INITIAL>markov_switching {BEGIN DYNARE_STATEMENT; return token::MARKOV_SWITCHING;}
|
||||
<INITIAL>svar {BEGIN DYNARE_STATEMENT; return token::SVAR;}
|
||||
<INITIAL>svar_global_identification_check {BEGIN DYNARE_STATEMENT; return token::SVAR_GLOBAL_IDENTIFICATION_CHECK;}
|
||||
<INITIAL>external_function {BEGIN DYNARE_STATEMENT; return token::EXTERNAL_FUNCTION;}
|
||||
/* End of a Dynare statement */
|
||||
<INITIAL>calib_smoother { BEGIN DYNARE_STATEMENT; return token::CALIB_SMOOTHER; }
|
||||
|
|
|
@ -1013,6 +1013,12 @@ ParsingDriver::add_constants_exclusion()
|
|||
svar_constants_exclusion = true;
|
||||
}
|
||||
|
||||
void
|
||||
ParsingDriver::add_svar_global_identification_check()
|
||||
{
|
||||
mod_file->addStatement(new SvarGlobalIdentificationCheckStatement);
|
||||
}
|
||||
|
||||
void
|
||||
ParsingDriver::do_sigma_e()
|
||||
{
|
||||
|
|
|
@ -485,6 +485,8 @@ public:
|
|||
void add_upper_cholesky();
|
||||
//! Svar_Identification Statement: restriction of form lower cholesky
|
||||
void add_lower_cholesky();
|
||||
//! Svar_Global_Identification_Check Statement
|
||||
void add_svar_global_identification_check();
|
||||
//! Forecast Statement
|
||||
void forecast();
|
||||
void set_trends();
|
||||
|
|
Loading…
Reference in New Issue