2018-10-25 16:31:53 +02:00
|
|
|
.. default-domain:: dynare
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. |br| raw:: html
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
<br>
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. highlight:: matlab
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
#########
|
|
|
|
Reporting
|
|
|
|
#########
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 17:30:28 +01:00
|
|
|
Dynare provides a simple interface for creating :math:`\text{\LaTeX}`
|
|
|
|
reports, comprised of :math:`\text{\LaTeX}` tables and ``PGFPLOTS/TikZ
|
|
|
|
graphs``. You can use the report as created through Dynare or pick out
|
|
|
|
the pieces (tables and graphs) you want for inclusion in your own
|
|
|
|
paper. Though Dynare provides a subset of options available through
|
|
|
|
``PGFPLOTS/TikZ``, you can easily modify the graphs created by Dynare
|
|
|
|
using the options available in the ``PGFPLOTS/TikZ`` manual. You can
|
|
|
|
either do this manually or by passing the options to
|
|
|
|
:opt:`miscTikzAxisOptions <miscTikzAxisOptions, STRING>` or
|
|
|
|
:opt:`graphMiscTikzAddPlotOptions <graphMiscTikzAddPlotOptions,
|
|
|
|
STRING>`.
|
2019-02-04 12:48:27 +01:00
|
|
|
|
|
|
|
Reports are created and modified by calling methods on class
|
|
|
|
objects. The objects are hierarchical, with the following order (from
|
|
|
|
highest to lowest): ``Report``, ``Page``, ``Section``,
|
|
|
|
``Graph/Table/Vspace``, ``Series``. For simplicity of syntax, we
|
|
|
|
abstract away from these classes, allowing you to operate directly on
|
|
|
|
a ``Report`` object, while maintaining the names of these classes in
|
2019-09-02 10:31:04 +02:00
|
|
|
the ``Report`` class methods you will use.
|
2019-02-04 12:48:27 +01:00
|
|
|
|
|
|
|
The report is created sequentially, command by command, hence the
|
|
|
|
order of the commands matters. When an object of a certain hierarchy
|
|
|
|
is inserted, all methods will function on that object until an object
|
|
|
|
of equal or greater hierarchy is added. Hence, once you add a ``Page``
|
|
|
|
to the report, every time you add a ``Section`` object, it will be
|
|
|
|
added to this ``Page`` until another ``Page`` is added to the report
|
|
|
|
(via :repmeth:`addPage`). This will become more clear with the example
|
|
|
|
at the end of the section.
|
|
|
|
|
2019-09-02 10:31:04 +02:00
|
|
|
Options to methods are passed differently than those to Dynare
|
2019-10-02 11:36:05 +02:00
|
|
|
commands. They take the form of named options to MATLAB functions
|
2019-02-04 12:48:27 +01:00
|
|
|
where the arguments come in pairs
|
|
|
|
(e.g. ``function_name(`option_1_name', `option_1_value',
|
|
|
|
`option_2_name', `option_2_value', ...)``, where ``option_X_name`` is
|
|
|
|
the name of the option while ``option_X_value`` is the value assigned
|
|
|
|
to that option). The ordering of the option pairs matters only in the
|
|
|
|
unusual case when an option is provided twice (probably
|
|
|
|
erroneously). In this case, the last value passed is the one that is
|
|
|
|
used.
|
|
|
|
|
|
|
|
Below, you will see a list of methods available for the Report class
|
|
|
|
and a clarifying example.
|
|
|
|
|
|
|
|
.. construct:: report
|
|
|
|
|
|
|
|
|br| Instantiates a ``Report`` object.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
*Options*
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: compiler, FILENAME
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 17:30:28 +01:00
|
|
|
The full path to the :math:`\text{\LaTeX}` compiler on your
|
|
|
|
system. If this option is not provided, Dynare will try to
|
|
|
|
find the appropriate program to compile :math:`\text{\LaTeX}` on your
|
|
|
|
system. Default is system dependent:
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
* Windows: the result of findtexmf ``--file-type=exe pdflatex``.
|
|
|
|
* macOS and Linux: the result of ``which pdflatex``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-09-05 11:08:34 +02:00
|
|
|
.. option:: directory, FILENAME
|
|
|
|
|
|
|
|
The path to the directory you want the report created in. Default:
|
|
|
|
current directory.
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: showDate, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Display the date and time when the report was
|
|
|
|
compiled. Default: ``true``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: fileName, FILENAME
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The file name to use when saving this report. Default: ``report.tex``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: header, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 17:30:28 +01:00
|
|
|
The valid :math:`\text{\LaTeX}` code to be included in the report before
|
2019-02-04 12:48:27 +01:00
|
|
|
``\begin{document}``. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-11-29 11:20:33 +01:00
|
|
|
.. option:: maketoc, BOOLEAN
|
|
|
|
|
|
|
|
Whether or not to make the table of contents. One entry is made per
|
|
|
|
page containing a title. Default: ``false``.
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: margin, DOUBLE
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The margin size. Default: ``2.5``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: marginUnit, `cm' | `in'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Units associated with the margin. Default: ```cm'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: orientation, `landscape' | `portrait'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Paper orientation: Default: ```portrait'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: paper, `a4' | `letter'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Paper size. Default: ```a4'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-11-29 11:46:33 +01:00
|
|
|
.. option:: reportDirName, FILENAME
|
|
|
|
|
|
|
|
The name of the folder in which to store the component parts of the
|
|
|
|
report (preamble, document, end). Default: ``tmpRepDir``.
|
|
|
|
|
|
|
|
.. option:: showDate, BOOLEAN
|
|
|
|
|
|
|
|
Display the date and time when the report was compiled. Default: true.
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: showOutput, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Print report creation progress to screen. Shows you the page
|
|
|
|
number as it is created and as it is written. This is useful
|
|
|
|
to see where a potential error occurs in report
|
|
|
|
creation. Default: ``true``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: title, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Report Title. Default: ``none``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. reportingmethod:: addPage
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
|br| Adds a Page to the Report.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
*Options*
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: footnote, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
A footnote to be included at the bottom of this page. Default: ``none``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: latex, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 17:30:28 +01:00
|
|
|
The valid :math:`\text{\LaTeX}` code to be used for this
|
|
|
|
page. Alows the user to create a page to be included in the
|
|
|
|
report by passing :math:`\text{\LaTeX}` code directly. If this option is
|
|
|
|
passed, the page itself will be saved in the :opt:`pageDirName
|
2019-09-05 11:08:34 +02:00
|
|
|
<pageDirName, FILENAME>` directory in the form ``page_X.tex``
|
2019-02-04 17:30:28 +01:00
|
|
|
where X refers to the page number. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: orientation, `landscape' | `portrait'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
See :opt:`orientation <orientation, `landscape' | `portrait'>`.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-09-05 11:08:34 +02:00
|
|
|
.. option:: pageDirName, FILENAME
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-09-05 11:08:34 +02:00
|
|
|
The name of the folder in which to store this page. Directory given is
|
|
|
|
relative to the `directory` option of the report class. Only used when
|
|
|
|
the :opt:`latex <latex, STRING>` command is passed. Default:
|
|
|
|
``tmpRepDir``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: paper, `a4' | `letter'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
See :opt:`paper <paper, `a4' | `letter'>`.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: title, STRING | CELL_ARRAY_STRINGS
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
With one entry (a STRING), the title of the page. With more
|
|
|
|
than one entry (a CELL_ARRAY_STRINGS), the title and
|
2019-02-04 17:30:28 +01:00
|
|
|
subtitle(s) of the page. Values passed must be valid
|
|
|
|
:math:`\text{\LaTeX}` code (e.g., ``%`` must be
|
|
|
|
``\%``). Default: ``none``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: titleFormat, STRING | CELL_ARRAY_STRINGS
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 17:30:28 +01:00
|
|
|
A string representing the valid :math:`\text{\LaTeX}` markup to use on
|
2019-02-04 12:48:27 +01:00
|
|
|
``title``. The number of cell array entries must be equal to
|
|
|
|
that of the ``title`` option if you do not want to use the
|
|
|
|
default value for the title (and subtitles). Default:
|
|
|
|
``\large\bfseries``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: titleTruncate, INTEGER
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Useful when automatically generating page titles that may
|
|
|
|
become too long, ``titleTruncate`` can be used to truncate a
|
|
|
|
title (and subsequent subtitles) when they pass the specified
|
|
|
|
number of characters. Default: ``.off``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. reportingmethod:: addSection
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
|br| Adds a ``Section`` to a ``Page``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
*Options*
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: cols, INTEGER
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The number of columns in the section. Default: ``1``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: height, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 17:30:28 +01:00
|
|
|
A string to be used with the ``\sectionheight`` :math:`\text{\LaTeX}`
|
2019-02-04 12:48:27 +01:00
|
|
|
command. Default: ``'!'``
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. reportingmethod:: addGraph
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
|br| Adds a ``Graph`` to a ``Section``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
*Options*
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: data, dseries
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The ``dseries`` that provides the data for the graph. Default: ``none``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: axisShape, `box' | `L'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The shape the axis should have. ```box'`` means that there is
|
|
|
|
an axis line to the left, right, bottom, and top of the
|
|
|
|
graphed line(s). 'L'`` means that there is an axis to the left
|
|
|
|
and bottom of the graphed line(s). Default: ```box'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-09-05 11:08:34 +02:00
|
|
|
.. option:: graphDirName, FILENAME
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-09-05 11:08:34 +02:00
|
|
|
The name of the folder in which to store this figure. Directory given
|
|
|
|
is relative to the `directory` option of the report class. Default:
|
2019-02-04 12:48:27 +01:00
|
|
|
``tmpRepDir``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphName, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The name to use when saving this figure. Default: something of
|
|
|
|
the form ``graph_pg1_sec2_row1_col3.tex``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: height, DOUBLE
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The height of the graph, in inches. Default: ``4.5``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: showGrid, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to display the major grid on the
|
|
|
|
graph. Default: ``true``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: showLegend, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to display the legend.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Unless you use the :opt:`graphLegendName <graphLegendName,
|
|
|
|
STRING>` option, the name displayed in the legend is the tex
|
|
|
|
name associated with the ``dseries``. You can modify this tex
|
|
|
|
name by using :dsermeth:`tex_rename <B =
|
|
|
|
tex_rename>`. Default: ``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: legendAt, NUMERICAL_VECTOR
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The coordinates for the legend location. If this option is
|
|
|
|
passed, it overrides the :opt:`legendLocation <legendLocation,
|
|
|
|
OPTION>` option. Must be of size ``2``. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: showLegendBox, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to display a box around the legend. Default: ``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: legendLocation, OPTION
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Where to place the legend in the graph. Possible values for OPTION are::
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
`south west' | `south east' | `north west' | `north east' | `outer north east'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Default: ```south east'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: legendOrientation, `vertical' | `horizontal'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Orientation of the legend. Default: ```horizontal'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: legendFontSize, OPTION
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The font size for legend entries. Possible values for OPTION are::
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
`tiny' | `scriptsize' | `footnotesize' | `small' | `normalsize' |
|
|
|
|
`large' | `Large' | `LARGE' | `huge' | `Huge'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Default: ``tiny``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: miscTikzAxisOptions, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
If you are comfortable with ``PGFPLOTS/TikZ``, you can use
|
|
|
|
this option to pass arguments directly to the
|
|
|
|
``PGFPLOTS/TikZ`` axis environment command. Specifically to be
|
|
|
|
used for desired ``PGFPLOTS/TikZ`` options that have not been
|
|
|
|
incorporated into Dynare Reporting. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: miscTikzPictureOptions, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
If you are comfortable with ``PGFPLOTS/TikZ``, you can use
|
|
|
|
this option to pass arguments directly to the
|
|
|
|
``PGFPLOTS/TikZ`` ``tikzpicture`` environment command. (e.g.,
|
|
|
|
to scale the graph in the x and y dimensions, you can pass
|
|
|
|
following to this option: 'xscale=2.5,
|
|
|
|
yscale=0.5'``). Specifically to be used for desired
|
|
|
|
``PGFPLOTS/TikZ`` options that have not been incorporated into
|
|
|
|
Dynare Reporting. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: seriesToUse, CELL_ARRAY_STRINGS
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The names of the series contained in the ``dseries`` provided
|
|
|
|
to the :opt:`data <data, dseries>` option. If empty, use all
|
|
|
|
series provided to ``data`` option. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: shade, dates
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The date range showing the portion of the graph that should be
|
|
|
|
shaded. Default: ``none``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: shadeColor, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The color to use in the shaded portion of the graph. All valid
|
|
|
|
color strings defined for use by ``PGFPLOTS/TikZ`` are
|
|
|
|
valid. A list of defined colors is::
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
'red', 'green', 'blue', 'cyan', 'magenta', 'yellow', 'black', 'gray',
|
|
|
|
'white','darkgray', 'lightgray', 'brown', 'lime', 'olive', 'orange',
|
|
|
|
'pink', 'purple', 'teal', 'violet'.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Furthermore, You can use combinations of these colors. For
|
|
|
|
example, if you wanted a color that is 20\% green and 80\%
|
|
|
|
purple, you could pass the string ``'green!20!purple'``. You
|
|
|
|
can also use RGB colors, following the syntax:
|
|
|
|
```rgb,255:red,231;green,84;blue,121'`` which corresponds to
|
|
|
|
the RGB color ``(231;84;121)``. More examples are available in
|
|
|
|
the section 4.7.5 of the ``PGFPLOTS/TikZ`` manual, revision
|
|
|
|
1.10. Default: ```green'``
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: shadeOpacity, DOUBLE
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The opacity of the shaded area, must be in ``[0,100]``. Default: ``20``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tickFontSize, OPTION
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The font size for x- and y-axis tick labels. Possible values
|
|
|
|
for OPTION are::
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
`tiny' | `scriptsize' | `footnotesize' | `small' | `normalsize' |
|
|
|
|
`large' | `Large' | `LARGE' | `huge' | `Huge'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Default: ``normalsize``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: title, STRING | CELL_ARRAY_STRINGS
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Same as :opt:`title <title, STRING | CELL_ARRAY_STRINGS>`,
|
|
|
|
just for graphs.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: titleFontSize, OPTION
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The font size for title. Possible values for OPTION are::
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
`tiny' | `scriptsize' | `footnotesize' | `small' | `normalsize' |
|
|
|
|
`large' | `Large' | `LARGE' | `huge' | `Huge'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Default: ``normalsize``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: titleFormat, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The format to use for the graph title. Unlike
|
|
|
|
:opt:`titleFormat <titleFormat, STRING | CELL_ARRAY_STRINGS>`,
|
|
|
|
due to a constraint of ``TikZ``, this format applies to the
|
|
|
|
title and subtitles. Default: ``TikZ`` default.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: width, DOUBLE
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The width of the graph, in inches. Default: ``6.0``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: writeCSV, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to write a CSV file with only the plotted
|
|
|
|
data. The file will be saved in the directory specified by
|
2019-09-05 11:08:34 +02:00
|
|
|
:opt:`graphDirName <graphDirName, FILENAME>` with the same base
|
2019-02-04 12:48:27 +01:00
|
|
|
name as specified by :opt:`graphName <graphName, STRING>` with
|
|
|
|
the ending ``.csv``. Default: ``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: xlabel, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The x-axis label. Default: ``none``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: ylabel, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The y-axis label. Default: ``none``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: xAxisTight, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Use a tight x axis. If false, uses ``PGFPLOTS/TikZ`` ``enlarge
|
|
|
|
x limits`` to choose appropriate axis size. Default: ``true``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: xrange, dates
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The boundary on the x-axis to display in the graph. Default: ``all``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: xTicks, NUMERICAL_VECTOR
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Used only in conjunction with :opt:`xTickLabels <xTickLabels,
|
|
|
|
CELL_ARRAY_STRINGS | `ALL'>`, this option denotes the
|
|
|
|
numerical position of the label along the x-axis. The
|
|
|
|
positions begin at ``1``. Default: the indices associated with
|
|
|
|
the first and last dates of the ``dseries`` and, if passed,
|
|
|
|
the index associated with the first date of the :opt:`shade
|
|
|
|
<shade, dates>` option.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: xTickLabels, CELL_ARRAY_STRINGS | `ALL'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The labels to be mapped to the ticks provided by
|
|
|
|
``xTicks``. Default: the first and last dates of the
|
|
|
|
``dseries`` and, if passed, the date first date of the
|
|
|
|
:opt:`shade <shade, dates>` option.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: xTickLabelAnchor, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-08-29 15:53:18 +02:00
|
|
|
Where to anchor the x tick label. Default: ```east'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: xTickLabelRotation, DOUBLE
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The amount to rotate the x tick labels by. Default: ``0``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: yAxisTight, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Use a tight y axis. If false, uses ``PGFPLOTS/TikZ`` ``enlarge
|
|
|
|
y limits`` to choose appropriate axis size. Default:
|
|
|
|
``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: yrange, NUMERICAL_VECTOR
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The boundary on the y-axis to display in the graph,
|
|
|
|
represented as a ``NUMERICAL_VECTOR`` of size ``2``, with the
|
|
|
|
first entry less than the second entry. Default: ``all``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: yTickLabelFixed, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Round the y tick labels to a fixed number of decimal places,
|
2019-08-29 15:53:18 +02:00
|
|
|
given by ``yTickLabelPrecision``. Default: ``true``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: yTickLabelPrecision, INTEGER
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-08-29 15:53:18 +02:00
|
|
|
The precision with which to report the ``yTickLabel``. Default: ``0``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: yTickLabelScaled, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Determines whether or not there is a common scaling factor for
|
|
|
|
the y axis. Default: ``true``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: yTickLabelZeroFill, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to fill missing precision spots with
|
|
|
|
zeros. Default: ``true``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: showZeroline, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Display a solid black line at :math:`y = 0`. Default: ``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: zeroLineColor, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The color to use for the zero line. Only used if
|
|
|
|
:opt:`showZeroLine <showZeroline, BOOLEAN>` is true. See the
|
|
|
|
explanation in :opt:`shadeColor <shadeColor, STRING>` for how
|
|
|
|
to use colors with reports. Default: ```black'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. reportingmethod:: addTable
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
|br| Adds a ``Table`` to a ``Section``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
*Options*
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: data, dseries
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
See :opt:`data <data, dseries>`.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: highlightRows, CELL_ARRAY_STRINGS
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
A cell array containing the colors to use for row
|
|
|
|
highlighting. See :opt:`shadeColor <shadeColor, STRING>` for
|
|
|
|
how to use colors with reports. Highlighting for a specific
|
|
|
|
row can be overridden by using the :opt:`tableRowColor
|
|
|
|
<tableRowColor, STRING>` option to
|
|
|
|
:repmeth:`addSeries`. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: showHlines, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to show horizontal lines separating the
|
|
|
|
rows. Default: ``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: precision, INTEGER
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-18 17:45:06 +01:00
|
|
|
The number of decimal places to report in the table data
|
|
|
|
(rounding done via the *round half away from zero*
|
|
|
|
method). Default: ``1``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: range, dates
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The date range of the data to be displayed. Default: ``all``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: seriesToUse, CELL_ARRAY_STRINGS
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
See :opt:`seriesToUse <seriesToUse, CELL_ARRAY_STRINGS>`.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-09-05 11:08:34 +02:00
|
|
|
.. option:: tableDirName, FILENAME
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-09-05 11:08:34 +02:00
|
|
|
The name of the folder in which to store this table. Directory given is
|
|
|
|
relative to the `directory` option of the report class. Default:
|
2019-02-04 12:48:27 +01:00
|
|
|
``tmpRepDir``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tableName, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The name to use when saving this table. Default: something of
|
|
|
|
the form ``table_pg1_sec2_row1_col3.tex``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: title, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Same as :opt:`title <title, STRING>`, just for tables.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: titleFormat, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-08-28 18:24:18 +02:00
|
|
|
Same as :opt:`titleFormat <titleFormat, STRING | CELL_ARRAY_STRINGS>`,
|
|
|
|
just for tables. Default: ``\large``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: vlineAfter, dates | CELL_ARRAY_DATES
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Show a vertical line after the specified date (or dates if a
|
|
|
|
cell array of dates is passed). Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: vlineAfterEndOfPeriod, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Show a vertical line after the end of every period (i.e. after
|
|
|
|
every year, after the fourth quarter, etc.). Default:
|
|
|
|
``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: showVlines, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to show vertical lines separating the
|
|
|
|
columns. Default: ``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: writeCSV, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to write a CSV file containing the data
|
|
|
|
displayed in the table. The file will be saved in the
|
|
|
|
directory specified by :opt:`tableDirName <tableDirName,
|
2019-09-05 11:08:34 +02:00
|
|
|
FILENAME>` with the same base name as specified by
|
2019-02-04 12:48:27 +01:00
|
|
|
:opt:`tableName <tableName, STRING>` with the ending
|
|
|
|
``.csv``. Default: ``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. reportingmethod:: addSeries
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
|br| Adds a ``Series`` to a ``Graph`` or a ``Table``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Options specific to graphs begin with ```graph'`` while options
|
|
|
|
specific to tables begin with ```table'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
*Options*
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: data, dseries
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
See :opt:`data <data, dseries>`.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphBar, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to display this series as a bar graph as oppsed
|
|
|
|
to the default of displaying it as a line graph. Default:
|
|
|
|
``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphFanShadeColor, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The shading color to use between a series and the
|
|
|
|
previously-added series in a graph. Useful for making fan
|
|
|
|
charts. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphFanShadeOpacity, INTEGER
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The opacity of the color passed in :opt:`graphFanShadeColor
|
|
|
|
<graphFanShadeColor, STRING>`. Default: ``50``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphBarColor, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The outline color of each bar in the bar graph. Only active if
|
|
|
|
:opt:`graphBar <graphBar, BOOLEAN>` is passed. Default:
|
|
|
|
```black'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphBarFillColor, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The fill color of each bar in the bar graph. Only active if
|
|
|
|
:opt:`graphBar <graphBar, BOOLEAN>` is passed. Default:
|
|
|
|
```black'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphBarWidth, DOUBLE
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The width of each bar in the bar graph. Only active if
|
|
|
|
:opt:`graphBar <graphBar, BOOLEAN>` is passed. Default: ``2``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphHline, DOUBLE
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Use this option to draw a horizontal line at the given
|
|
|
|
value. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphLegendName, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The name to display in the legend for this series, passed as
|
2019-02-04 17:30:28 +01:00
|
|
|
valid :math:`\text{\LaTeX}` (e.g., ``GDP_{US}, $\alpha$,
|
2019-02-04 12:48:27 +01:00
|
|
|
\color{red}GDP\color{black}``). Will be displayed only if the
|
|
|
|
``data`` and :opt:`showLegend <showLegend, BOOLEAN>` options
|
|
|
|
have been passed. Default: the tex name of the series.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphLineColor, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Color to use for the series in a graph. See the explanation in
|
|
|
|
:opt:`shadeColor <shadeColor, STRING>` for how to use colors
|
|
|
|
with reports. Default: ```black'``
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphLineStyle, OPTION
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Line style for this series in a graph. Possible values for OPTION are::
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
`none' | `solid' | `dotted' | `densely dotted' | `loosely dotted' | `dashed' |
|
|
|
|
`densely dashed' | `loosely dashed' | `dashdotted' | `densely dashdotted' |
|
|
|
|
`loosely dashdotted' | `dashdotdotted' | `densely dashdotdotted' |
|
|
|
|
`loosely dashdotdotted'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Default: ```solid'``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphLineWidth DOUBLE
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Line width for this series in a graph. Default: ``0.5``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphMarker, OPTION
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The Marker to use on this series in a graph. Possible values
|
|
|
|
for OPTION are::
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
`x' | `+' | `-' | `|' | `o' | `asterisk' | `star' | `10-pointed star' |
|
|
|
|
`oplus' | `oplus*' | `otimes' | `otimes*' | `square' | `square*' |
|
|
|
|
`triangle' | `triangle*' | `diamond' | `diamond*' | `halfdiamond*' |
|
|
|
|
`halfsquare*' | `halfsquare right*' | `halfsquare left*' | `Mercedes star' |
|
|
|
|
`Mercedes star flipped' | `halfcircle' | `halfcircle*' | `pentagon' |
|
|
|
|
`pentagon star'
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Default: ``none``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphMarkerEdgeColor, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The edge color of the graph marker. See the explanation in
|
|
|
|
:opt:`shadeColor <shadeColor, STRING>` for how to use colors
|
|
|
|
with reports. Default: ``graphLineColor``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphMarkerFaceColor, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The face color of the graph marker. See the explanation in
|
|
|
|
:opt:`shadeColor <shadeColor, STRING>` for how to use colors
|
|
|
|
with reports. Default: ``graphLineColor``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphMarkerSize, DOUBLE
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The size of the graph marker. Default: ``1``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphMiscTikzAddPlotOptions, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
If you are comfortable with ``PGFPLOTS/TikZ``, you can use
|
|
|
|
this option to pass arguments directly to the
|
|
|
|
``PGFPLOTS/TikZ`` ``addPlots`` command. (e.g., Instead of
|
|
|
|
passing the marker options above, you can pass a string such
|
|
|
|
as the following to this option: ```mark=halfcircle*,mark
|
|
|
|
options={rotate=90,scale=3}'``). Specifically to be used for
|
|
|
|
desired ``PGFPLOTS/TikZ`` options that have not been
|
|
|
|
incorporated into Dynare Reproting. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphShowInLegend, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to show this series in the legend, given that
|
|
|
|
the :opt:`showLegend <showLegend, BOOLEAN>` option was passed
|
|
|
|
to :repmeth:`addGraph`. Default: ``true``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: graphVline, dates
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Use this option to draw a vertical line at a given
|
|
|
|
date. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tableDataRhs, dseries
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
A series to be added to the right of the current
|
|
|
|
series. Usefull for displaying aggregate data for a
|
|
|
|
series. e.g if the series is quarterly ``tableDataRhs`` could
|
|
|
|
point to the yearly averages of the quarterly series. This
|
|
|
|
would cause quarterly data to be displayed followed by annual
|
|
|
|
data. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tableRowColor, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The color that you want the row to be. Predefined values
|
|
|
|
include ``LightCyan`` and ``Gray``. Default: ``white``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tableRowIndent, INTEGER
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The number of times to indent the name of the series in the
|
|
|
|
table. Used to create subgroups of series. Default: ``0``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tableShowMarkers, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
In a Table, if ``true``, surround each cell with brackets and
|
|
|
|
color it according to :opt:`tableNegColor <tableNegColor,
|
|
|
|
LATEX_COLOR>` and :opt:`tablePosColor <tablePosColor,
|
|
|
|
LATEX_COLOR>`. No effect for graphs. Default: ``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tableAlignRight, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to align the series name to the right of the
|
|
|
|
cell. Default: ``false``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tableMarkerLimit, DOUBLE
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
For values less than :math:`-1*\texttt{tableMarkerLimit}`,
|
|
|
|
mark the cell with the color denoted by tableNegColor. For
|
|
|
|
those greater than ``tableMarkerLimit``, mark the cell with
|
|
|
|
the color denoted by tablePosColor. Default: ``1e-4``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tableNaNSymb, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Replace ``NaN`` values with the text in this option. Default: ``NaN``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tableNegColor, LATEX_COLOR
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The color to use when marking Table data that is less than
|
|
|
|
zero. Default: ```red'``
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tablePrecision, INTEGER
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The number of decimal places to report in the table
|
|
|
|
data. Default: the value set by :opt:`precision <precision,
|
|
|
|
INTEGER>`.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tablePosColor, LATEX_COLOR
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The color to use when marking Table data that is greater than
|
|
|
|
zero. Default: ```blue'``
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: tableSubSectionHeader, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
A header for a subsection of the table. No data will be
|
|
|
|
associated with it. It is equivalent to adding an empty series
|
|
|
|
with a name. Default: ``''``
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: zeroTol, DOUBLE
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The zero tolerance. Anything smaller than ``zeroTol`` and
|
|
|
|
larger than ``-zeroTol`` will be set to zero before being
|
|
|
|
graphed or written to the table. Default: ``1e-6``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. reportingmethod:: addParagraph
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
|br| Adds a ``Paragraph`` to a ``Section``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The ``Section`` can only be comprised of ``Paragraphs`` and must
|
|
|
|
only have 1 column.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
*Options*
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: balancedCols, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Determines whether the text is spread out evenly across the
|
|
|
|
columns when the ``Paragraph`` has more than one
|
|
|
|
column. Default: ``true``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: cols, INTEGER
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The number of columns for the ``Paragraph``. Default: ``1``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: heading, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The heading for the ``Paragraph`` (like a section
|
2019-02-04 17:30:28 +01:00
|
|
|
heading). The string must be valid :math:`\text{\LaTeX}` code. Default:
|
2019-02-04 12:48:27 +01:00
|
|
|
``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: indent, BOOLEAN
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Whether or not to indent the paragraph. Default: ``true``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: text, STRING
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 17:30:28 +01:00
|
|
|
The paragraph itself. The string must be valid :math:`\text{\LaTeX}`
|
2019-02-04 12:48:27 +01:00
|
|
|
code. Default: ``empty``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. reportingmethod:: addVspace
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
|br| Adds a ``Vspace`` (vertical space) to a ``Section``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
*Options*
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: hline, INTEGER
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The number of horizontal lines to be inserted. Default: ``0``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. option:: number, INTEGER
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The number of new lines to be inserted. Default: ``1``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. reportingmethod:: write
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 17:30:28 +01:00
|
|
|
|br| Writes the :math:`\text{\LaTeX}` representation of this
|
|
|
|
``Report``, saving it to the file specified by :opt:`filename
|
|
|
|
<fileName, FILENAME>`.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
.. reportingmethod:: compile
|
2018-10-25 16:31:53 +02:00
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
|br| Compiles the report written by ``write`` into a ``pdf``
|
|
|
|
file. If the report has not already been written (determined by
|
|
|
|
the existence of the file specified by :opt:`filename <fileName,
|
|
|
|
FILENAME>`, ``write`` is called.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
*Options*
|
|
|
|
|
|
|
|
.. option:: compiler, FILENAME
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Like :opt:`compiler <compiler, FILENAME>`, except will not
|
|
|
|
overwrite the value of ``compiler`` contained in the report
|
|
|
|
object. Hence, passing the value here is useful for using
|
2019-02-04 17:30:28 +01:00
|
|
|
different :math:`\text{\LaTeX}` compilers or just for passing
|
|
|
|
the value at the last minute.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
.. option:: showOutput, BOOLEAN
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Print the compiler output to the screen. Useful for debugging
|
2019-02-04 17:30:28 +01:00
|
|
|
your code as the :math:`\text{\LaTeX}` compiler hangs if there is a
|
2019-02-04 12:48:27 +01:00
|
|
|
problem. Default: the value of :opt:`showOutput <showOutput,
|
|
|
|
BOOLEAN>`.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
.. option:: showReport, BOOLEAN
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
Open the compiled report (works on Windows and macOS on
|
2019-10-02 11:36:05 +02:00
|
|
|
MATLAB). Default: ``true``.
|
2018-10-25 16:31:53 +02:00
|
|
|
|
|
|
|
|
|
|
|
*Example*
|
|
|
|
|
2019-02-04 12:48:27 +01:00
|
|
|
The following code creates a one page report. The first part of the
|
|
|
|
page contains two graphs displayed across two columns and one row. The
|
|
|
|
bottom of the page displays a centered table::
|
|
|
|
|
|
|
|
%% Create dseries
|
|
|
|
dsq = dseries(`quarterly.csv');
|
|
|
|
dsa = dseries(`annual.csv');
|
|
|
|
dsca = dseries(`annual_control.csv');
|
|
|
|
|
|
|
|
%% Report
|
|
|
|
rep = report();
|
|
|
|
|
|
|
|
%% Page 1
|
2019-09-02 10:31:04 +02:00
|
|
|
rep.addPage('title', {'My Page Title', 'My Page Subtitle'}, ...
|
|
|
|
'titleFormat', {'\large\bfseries', '\large'});
|
2019-02-04 12:48:27 +01:00
|
|
|
|
|
|
|
% Section 1
|
2019-09-02 10:31:04 +02:00
|
|
|
rep.addSection('cols', 2);
|
|
|
|
|
|
|
|
rep.addGraph('title', 'Graph Column 1', 'showLegend', true, ...
|
|
|
|
'xrange', dates('2007q1'):dates('2013q4'), ...
|
|
|
|
'shade', dates('2012q2'):dates('2013q4'));
|
|
|
|
rep.addSeries('data', dsq{'GROWTH_US'}, 'graphLineColor', 'blue', ...
|
|
|
|
'graphLineStyle', 'loosely dashed', 'graphLineWidth', 1);
|
|
|
|
rep.addSeries('data', dsq{'GROWTH_EU'}, 'graphLineColor', 'green', ...
|
|
|
|
'graphLineWidth', 1.5);
|
|
|
|
|
|
|
|
rep.addGraph('title', 'Graph Column 2', 'showLegend', true, ...
|
|
|
|
'xrange', dates('2007q1'):dates('2013q4'), ...
|
|
|
|
'shade', dates('2012q2'):dates('2013q4'));
|
|
|
|
rep.addSeries('data', dsq{'GROWTH_JA'}, 'graphLineColor', 'blue', ...
|
|
|
|
'graphLineWidth', 1);
|
|
|
|
rep.addSeries('data', dsq{'GROWTH_RC6'}, 'graphLineColor', 'green', ...
|
|
|
|
'graphLineStyle', 'dashdotdotted', 'graphLineWidth', 1.5);
|
2019-02-04 12:48:27 +01:00
|
|
|
|
|
|
|
% Section 2
|
2019-09-02 10:31:04 +02:00
|
|
|
rep.addVspace('number', 15);
|
|
|
|
rep.addSection();
|
|
|
|
rep.addTable('title', 'Table 1', 'range', dates('2012Y'):dates('2014Y'));
|
|
|
|
shortNames = {'US', 'EU'};
|
|
|
|
longNames = {'United States', 'Euro Area'};
|
2019-02-04 12:48:27 +01:00
|
|
|
for i=1:length(shortNames)
|
2019-09-02 10:31:04 +02:00
|
|
|
rep.addSeries('data', dsa{['GROWTH_' shortNames{i}]});
|
|
|
|
delta = dsa{['GROWTH_' shortNames{i}]}-dsca{['GROWTH_' shortNames{i}]};
|
|
|
|
delta.tex_rename_('$\Delta$');
|
|
|
|
rep.addSeries('data', delta, ...
|
|
|
|
'tableShowMarkers', true, 'tableAlignRight', true);
|
2019-02-04 12:48:27 +01:00
|
|
|
end
|
|
|
|
|
|
|
|
%% Write & Compile Report
|
|
|
|
rep.write();
|
|
|
|
rep.compile();
|
2019-09-02 12:26:16 +02:00
|
|
|
|
|
|
|
Once compiled, the report looks like:
|
|
|
|
|
|
|
|
.. image:: _static/report.png
|