Commit edca7465 authored by Sébastien Villemot's avatar Sébastien Villemot
Browse files

Preprocessor iface and doc for nodisplay and graph_format

Closes: #216
parent 6cc3be72
......@@ -3002,8 +3002,22 @@ them is the default).
Don't print moments of the endogenous variables (printing them is the
default).
@item nograph.
Doesn't do the graphs. Useful for loops.
@item nograph
@anchor{nograph} Do not create graphs (which implies that they are not
saved to the disk nor displayed). If this option is not used, graphs
will be saved to disk (to the format specified by @code{graph_format}
option) and displayed to screen (unless @code{nodisplay} option is
used).
@item nodisplay
@anchor{nodisplay} Do not display the graphs, but still save them to disk
(unless @code{nograph} is used).
@item graph_format = @var{FORMAT}
@anchor{graph_format}
Specify the file format for graphs saved to disk. Possible values are
@code{eps} (the default), @code{pdf} and @code{fig} (the latter is not
available under Octave).
@item noprint
Don't print anything. Useful for loops.
......@@ -3841,8 +3855,13 @@ result in absurd prior densities.
Default value is @code{1}.
@item nograph
@anchor{nograph}
No graphs should be plotted
@xref{nograph}.
@item nodisplay
@xref{nodisplay}.
@item graph_format = @var{FORMAT}
@xref{graph_format}.
@item lik_init = @var{INTEGER}
@anchor{lik_init}
......@@ -4648,7 +4667,14 @@ Number of periods of the forecast. Default: @code{40}
interval. Default: @code{0.90}
@item nograph
Don't display graphics.
@xref{nograph}.
@item nodisplay
@xref{nodisplay}.
@item graph_format = @var{FORMAT}
@xref{graph_format}.
@end table
@customhead{Initial Values}
......@@ -5252,6 +5278,8 @@ command. These are:
@item @code{prefilter}
@item @code{presample}
@item @code{nograph}
@item @code{nodisplay}
@item @code{graph_format}
@item @code{conf_sig}
@item @code{loglinear}
@item @code{mode_file}
......@@ -5567,6 +5595,12 @@ Critical value for correlation @math{\rho}: plot couples of parmaters with
@item nograph
@xref{nograph}.
@item nodisplay
@xref{nodisplay}.
@item graph_format = @var{FORMAT}
@xref{graph_format}.
@item conf_sig = @var{DOUBLE}
@xref{conf_sig}.
......
......@@ -102,7 +102,7 @@ class ParsingDriver;
%token <string_val> FLOAT_NUMBER
%token DEFAULT FIXED_POINT
%token FORECAST K_ORDER_SOLVER INSTRUMENTS PRIOR SHIFT MEAN STDEV VARIANCE MODE INTERVAL SHAPE DOMAINN
%token GAMMA_PDF GRAPH CONDITIONAL_VARIANCE_DECOMPOSITION NOCHECK TRANSFORM_LOGPOW STD
%token GAMMA_PDF GRAPH GRAPH_FORMAT CONDITIONAL_VARIANCE_DECOMPOSITION NOCHECK TRANSFORM_LOGPOW STD
%token HISTVAL HOMOTOPY_SETUP HOMOTOPY_MODE HOMOTOPY_STEPS HOMOTOPY_FORCE_CONTINUE HP_FILTER HP_NGRID
%token IDENTIFICATION INF_CONSTANT INITVAL INITVAL_FILE BOUNDS JSCALE INIT
%token <string_val> INT_NUMBER
......@@ -115,7 +115,7 @@ class ParsingDriver;
%token MODE_CHECK MODE_COMPUTE MODE_FILE MODEL MODEL_COMPARISON MODEL_INFO MSHOCKS ABS SIGN
%token MODIFIEDHARMONICMEAN MOMENTS_VARENDO DIFFUSE_FILTER SUB_DRAWS
%token <string_val> NAME
%token NAN_CONSTANT NO_STATIC NOBS NOCONSTANT NOCORR NODIAGNOSTIC NOFUNCTIONS
%token NAN_CONSTANT NO_STATIC NOBS NOCONSTANT NODISPLAY NOCORR NODIAGNOSTIC NOFUNCTIONS
%token NOGRAPH NOMOMENTS NOPRINT NORMAL_PDF
%token OBSERVATION_TRENDS OPTIM OPTIM_WEIGHTS ORDER OSR OSR_PARAMS MAX_DIM_COVA_GROUP ADVANCED
%token PARAMETERS PARAMETER_SET PARTIAL_INFORMATION PERIODS PLANNER_OBJECTIVE PLOT_CONDITIONAL_FORECAST PLOT_PRIORS PREFILTER PRESAMPLE
......@@ -150,7 +150,7 @@ class ParsingDriver;
%token VLISTLOG VLISTPER
%token RESTRICTION RESTRICTION_FNAME CROSS_RESTRICTIONS NLAGS CONTEMP_REDUCED_FORM REAL_PSEUDO_FORECAST
%token NONE DUMMY_OBS NSTATES INDXSCALESSTATES NO_BAYESIAN_PRIOR SPECIFICATION SIMS_ZHA
%token <string_val> ALPHA BETA ABAND NINV CMS NCMS CNUM GAMMA INV_GAMMA INV_GAMMA1 INV_GAMMA2 NORMAL UNIFORM
%token <string_val> ALPHA BETA ABAND NINV CMS NCMS CNUM GAMMA INV_GAMMA INV_GAMMA1 INV_GAMMA2 NORMAL UNIFORM EPS PDF FIG
%token GSIG2_LMDM Q_DIAG FLAT_PRIOR NCSK NSTD
%token INDXPARR INDXOVR INDXAP APBAND INDXIMF IMFBAND INDXFORE FOREBAND INDXGFOREHAT INDXGIMFHAT
%token INDXESTIMA INDXGDLS EQ_MS FILTER_COVARIANCE FILTER_DECOMPOSITION
......@@ -915,6 +915,8 @@ stoch_simul_options : o_dr_algo
| o_nofunctions
| o_nomoments
| o_nograph
| o_nodisplay
| o_graph_format
| o_irf
| o_irf_shocks
| o_relative_irf
......@@ -1448,6 +1450,8 @@ estimation_options : o_datafile
| o_lik_algo
| o_lik_init
| o_nograph
| o_nodisplay
| o_graph_format
| o_conf_sig
| o_mh_replic
| o_mh_drop
......@@ -2020,6 +2024,8 @@ dynare_sensitivity_option : o_gsa_identification
| o_prefilter
| o_presample
| o_nograph
| o_nodisplay
| o_graph_format
| o_conf_sig
| o_loglinear
| o_mode_file
......@@ -2066,6 +2072,8 @@ forecast_options: forecast_option
forecast_option: o_periods
| o_conf_sig
| o_nograph
| o_nodisplay
| o_graph_format
;
conditional_forecast : CONDITIONAL_FORECAST '(' conditional_forecast_options ')' ';'
......@@ -2206,10 +2214,18 @@ o_presample : PRESAMPLE EQUAL INT_NUMBER { driver.option_num("presample", $3); }
o_lik_algo : LIK_ALGO EQUAL INT_NUMBER { driver.option_num("lik_algo", $3); };
o_lik_init : LIK_INIT EQUAL INT_NUMBER { driver.option_num("lik_init", $3); };
o_nograph : NOGRAPH
{ driver.option_num("nograph","1"); };
{ driver.option_num("nograph","1"); }
| GRAPH
{ driver.option_num("nograph", "0"); }
;
o_nodisplay : NODISPLAY { driver.option_num("nodisplay","1"); };
o_graph_format : GRAPH_FORMAT EQUAL EPS
{ driver.option_str("graph_format", "eps"); }
| GRAPH_FORMAT EQUAL FIG
{ driver.option_str("graph_format", "fig"); }
| GRAPH_FORMAT EQUAL PDF
{ driver.option_str("graph_format", "pdf"); }
;
o_subsample_name : symbol EQUAL date_number ':' date_number
{ driver.set_subsample_name_equal_to_date_range($1, $3, $5); }
;
......@@ -2640,6 +2656,9 @@ symbol : NAME
| INV_GAMMA2
| NORMAL
| UNIFORM
| EPS
| PDF
| FIG
;
%%
......
......@@ -220,6 +220,11 @@ string eofbuff;
<DYNARE_STATEMENT>lik_init {return token::LIK_INIT;}
<DYNARE_STATEMENT>graph {return token::GRAPH;}
<DYNARE_STATEMENT>nograph {return token::NOGRAPH;}
<DYNARE_STATEMENT>nodisplay {return token::NODISPLAY;}
<DYNARE_STATEMENT>graph_format {return token::GRAPH_FORMAT;}
<DYNARE_STATEMENT>eps {yylval->string_val = new string(yytext); return token::EPS;}
<DYNARE_STATEMENT>pdf {yylval->string_val = new string(yytext); return token::PDF;}
<DYNARE_STATEMENT>fig {yylval->string_val = new string(yytext); return token::FIG;}
<DYNARE_STATEMENT>print {return token::PRINT;}
<DYNARE_STATEMENT>noprint {return token::NOPRINT;}
<DYNARE_STATEMENT>conf_sig {return token::CONF_SIG;}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment