.. _output_options:

OUTPUT_OPTIONS
#################

An optional section that controls the output from a script.

The |output_options| section is available in the following scripts:-

* :ref:`sim_script`
* :ref:`msim_script`
* :ref:`mgen_script`
* :ref:`mtut_script`

The |output_options| contain a |script_type| specific set of extra options.

.. comment
    technically the sum scripts have an OUTPUT_OPTIONS, but it's not used much
    * :ref:`tutsum_script`
    * :ref:`gensum_script`
    * :ref:`fitsum_script`
    
.. _output_options_sim_example:

Example OUTPUT_OPTIONS for sim_script
=======================================

The |output_options| in a :ref:`sim_script` contain a single field 'sim_time_step'. For example the following:-

.. code-block:: pyml

    OUTPUT_OPTIONS:
        sim_time_step: 0.5

means that |popy| will simulate a |px| value at every 0.5 time units when simulating from a |pkpd| model.

An alternative (and default setting) is:-

.. code-block:: pyml

    OUTPUT_OPTIONS:
        sim_time_step: -1.0
        
Which only simulates |px| model predictions for time points present in the |data_file|, |ie| dense time point sampling is switched off by using a negative 'sim_time_step'.

        
.. _output_options_msim_example:

Example OUTPUT_OPTIONS for msim_script
=======================================

The |output_options| in a :ref:`msim_script` contain the 'sim_time_step' and 'n_pop_samples' fields. For example the following:-

.. code-block:: pyml

    OUTPUT_OPTIONS:
        sim_time_step: -1.0
        n_pop_samples: 100

In a :ref:`msim_script` it is simpler to keep 'sim_time_step' set to -1.0. As you usually want the noise |cx| samples to be at the same time points as the original |data_file| when creating a |vpc|.

The 'n_pop_samples' allows you to vary the number of population samples you collect for your |vpc|. Generally the more the better, but you have to wait longer for more samples.
    
.. _output_options_mtut_mgen_example:

Example OUTPUT_OPTIONS for mtut_script and mgen_script
=========================================================

The |output_options| in a :ref:`mtut_script` and  :ref:`mgen_script` allow you to control the number of population samples, for example:-

.. code-block:: pyml

    OUTPUT_OPTIONS: {n_pop_samples: 30}

The more population samples the more comprehensive your data, but the longer the computation will take.

