:orphan:

.. The content of this file was generated
.. automatically by the popy.conf.fio.rstdoc_writer module


.. _sim_spec:



.. _sim-method_options_spec:

METHOD_OPTIONS
**************

Type: :term:`dict_record <dict_record>`

method options for sim_script

Example:-

.. code-block:: pyml

    METHOD_OPTIONS:
        py_module: sim
        rand_seed: 12345
        float_format: default


.. _sim-method_options-py_module_spec:

py_module
=========

Type: :term:`one_of(sim) <one_of>`

Python module required to process this script file

Example:-

.. code-block:: pyml

    py_module: sim


.. _sim-method_options-rand_seed_spec:

rand_seed
=========

Type: :term:`int <int>` / :term:`auto <auto>`

Option to set seed to make run result
reproducible -e.g. when debugging.

Example:-

.. code-block:: pyml

    rand_seed: 12345


.. _sim-method_options-float_format_spec:

float_format
============

Type: :term:`str <str>`

Format string for numerical output

Example:-

.. code-block:: pyml

    float_format: default


.. _sim-parallel_spec:

PARALLEL
********

Type: :term:`one_of_record <one_of_record>`

one of many possible servers

Example:-

.. code-block:: pyml

    PARALLEL:
        SINGLE: {}


.. _sim-parallel-single_spec:

SINGLE
======

Type: :term:`dict_record <dict_record>`

single process server spec.

Example:-

.. code-block:: pyml

    SINGLE: {}


.. _sim-parallel-mpi_workers_spec:

MPI_WORKERS
===========

Type: :term:`dict_record <dict_record>`

MPI local server spec.

Example:-

.. code-block:: pyml

    MPI_WORKERS:
        n_workers: auto


.. _sim-parallel-mpi_workers-n_workers_spec:

n_workers
---------

Type: :term:`int <int>` / :term:`auto <auto>`

Number of workers to use on this machine, defaults to number of processors, but could be more or fewer.

Example:-

.. code-block:: pyml

    n_workers: auto


.. _sim-description_spec:

DESCRIPTION
***********

Type: :term:`dict_record <dict_record>`

Description fields for script.

Example:-

.. code-block:: pyml

    DESCRIPTION:
        name: example
        title: A PKPD model
        author: A.N. Other
        abstract: |
        keywords: []


.. _sim-description-name_spec:

name
====

Type: :term:`str <str>`

Unique name used to distinguish script

Example:-

.. code-block:: pyml

    name: example


.. _sim-description-title_spec:

title
=====

Type: :term:`str <str>`

A longer text string that could serve as a title

Example:-

.. code-block:: pyml

    title: A PKPD model


.. _sim-description-author_spec:

author
======

Type: :term:`str <str>`

Author of the model

Example:-

.. code-block:: pyml

    author: A.N. Other


.. _sim-description-abstract_spec:

abstract
========

Type: :term:`verbatim <verbatim>`

Abstract paragraph describing model

Example:-

.. code-block:: pyml

    abstract: |


.. _sim-description-keywords_spec:

keywords
========

Type: :term:`list <list>`

Keywords list used to categorise models.

Example:-

.. code-block:: pyml

    keywords: []


.. _sim-file_paths_spec:

FILE_PATHS
**********

Type: :term:`dict_record <dict_record>`

file paths

Example:-

.. code-block:: pyml

    FILE_PATHS:
        input_data_file: input.csv
        extra_data_file: none
        output_folder: auto
        temp_folder: auto
        log_folder: auto
        output_file_ext: ['svg']
        delete_old_files_flag: False
        solutions:
            pop: ./path_to_final_pop_solution.pyml
            indiv: ./path_to_final_indiv_solution.pyml


.. _sim-file_paths-input_data_file_spec:

input_data_file
===============

Type: :term:`input_file <input_file>`

path to input comma separated value file in popy data format

Example:-

.. code-block:: pyml

    input_data_file: input.csv


.. _sim-file_paths-extra_data_file_spec:

extra_data_file
===============

Type: :term:`input_file <input_file>` / :term:`none <none>`

path to extra comma separated value file in popy data format

Example:-

.. code-block:: pyml

    extra_data_file: none


.. _sim-file_paths-output_folder_spec:

output_folder
=============

Type: :term:`output_folder <output_folder>` / :term:`auto <auto>`

Output folder - results of computation stored here

Example:-

.. code-block:: pyml

    output_folder: auto


.. _sim-file_paths-temp_folder_spec:

temp_folder
===========

Type: :term:`output_folder <output_folder>` / :term:`auto <auto>`

Temp folder - temporary files stored here

Example:-

.. code-block:: pyml

    temp_folder: auto


.. _sim-file_paths-log_folder_spec:

log_folder
==========

Type: :term:`output_folder <output_folder>` / :term:`auto <auto>`

Log folder - log files stored here

Example:-

.. code-block:: pyml

    log_folder: auto


.. _sim-file_paths-output_file_ext_spec:

output_file_ext
===============

Type: :term:`list_of(pdf,png,svg) <list_of>`

Output file extension - determines graphical output file format.

Example:-

.. code-block:: pyml

    output_file_ext: ['svg']


.. _sim-file_paths-delete_old_files_flag_spec:

delete_old_files_flag
=====================

Type: :term:`bool <bool>`

Option to delete any existing files before running.

Example:-

.. code-block:: pyml

    delete_old_files_flag: False


.. _sim-file_paths-solutions_spec:

solutions
=========

Type: :term:`dict <dict>`

Solutions to compare

Example:-

.. code-block:: pyml

    solutions:
        pop: ./path_to_final_pop_solution.pyml
        indiv: ./path_to_final_indiv_solution.pyml


.. _sim-data_fields_spec:

DATA_FIELDS
***********

Type: :term:`dict_record <dict_record>`

data fields for popy.dat.fields object

Example:-

.. code-block:: pyml

    DATA_FIELDS:
        type_field: TYPE
        id_field: ID
        time_field: TIME


.. _sim-data_fields-type_field_spec:

type_field
==========

Type: :term:`str <str>`

Field name in data file that contains row type info, e.g. obs/dose etc

Example:-

.. code-block:: pyml

    type_field: TYPE


.. _sim-data_fields-id_field_spec:

id_field
========

Type: :term:`str <str>`

Field name in data file that contains identity string for each data row e.g. obs/dose etc

Example:-

.. code-block:: pyml

    id_field: ID


.. _sim-data_fields-time_field_spec:

time_field
==========

Type: :term:`str <str>`

Field name in data file that contains time or event for each data row

Example:-

.. code-block:: pyml

    time_field: TIME


.. _sim-preprocess_spec:

PREPROCESS
**********

Type: :term:`verbatim <verbatim>`

Code that preprocesses the input data.
Use this to filter rows and create derived covariates.

Example:-

.. code-block:: pyml

    PREPROCESS: |


.. _sim-states_spec:

STATES
******

Type: :term:`verbatim <verbatim>`

Optional section for setting initial values of s[X] variables
can also set slabel[X] text labels.

Example:-

.. code-block:: pyml

    STATES: |


.. _sim-derivatives_spec:

DERIVATIVES
***********

Type: :term:`verbatim <verbatim>`

Define how the covariates and effects determine flows
between compartments.

Example:-

.. code-block:: pyml

    DERIVATIVES: |
        # s[DEPOT,CENTRAL,PERI] = @dep_two_cmp_cl{dose:@bolus{amt:c[AMT]}}
        d[DEPOT] = @bolus{amt:c[AMT]} - m[KA]*s[DEPOT]
        d[CENTRAL] = m[KA]*s[DEPOT] - s[CENTRAL]*m[CL]/m[V1] - s[CENTRAL]*m[Q]/m[V1]  + s[PERI]*m[Q]/m[V2]
        d[PERI] = s[CENTRAL]*m[Q]/m[V1] - s[PERI]*m[Q]/m[V2]


.. _sim-predictions_spec:

PREDICTIONS
***********

Type: :term:`verbatim <verbatim>`

Define the final predicted m[X] variables to be output
by the compartment model system.

Example:-

.. code-block:: pyml

    PREDICTIONS: |
        p[DV_CENTRAL] = s[CENTRAL]/m[V1]
        var = m[ANOISE]**2 + m[PNOISE]**2 * p[DV_CENTRAL]**2
        c[DV_CENTRAL] ~ norm(p[DV_CENTRAL], var)


.. _sim-postprocess_spec:

POSTPROCESS
***********

Type: :term:`verbatim <verbatim>`

Code that postprocesses the output data.
Use this to filter rows and create derived covariates, after 
the main data curves have been generated.

Example:-

.. code-block:: pyml

    POSTPROCESS: |


.. _sim-ode_solver_spec:

ODE_SOLVER
**********

Type: :term:`one_of_record <one_of_record>`

one of many possible solvers

Example:-

.. code-block:: pyml

    ODE_SOLVER:
        SCIPY_ODEINT:
            atol: 1e-06
            rtol: 1e-06
            max_nsteps: 10000000
            use_supersections: True
            use_jacobian: False
            use_sens: False
            use_tcrit: False


.. _sim-ode_solver-no_solver_spec:

NO_SOLVER
=========

Type: :term:`dict_record <dict_record>`

Null method for blank derivatives.

Example:-

.. code-block:: pyml

    NO_SOLVER: {}


.. _sim-ode_solver-analytic_spec:

ANALYTIC
========

Type: :term:`dict_record <dict_record>`

Analytic method for solving ODE

Example:-

.. code-block:: pyml

    ANALYTIC:
        use_supersections: auto
        use_sens: True


.. _sim-ode_solver-analytic-use_supersections_spec:

use_supersections
-----------------

Type: :term:`bool <bool>` / :term:`auto <auto>`

Option to combine sections into supersections, which can make PoPy run faster, however with discontinuous ODE params you may need to turn this off (closer to nonmem approach).

Example:-

.. code-block:: pyml

    use_supersections: auto


.. _sim-ode_solver-analytic-use_sens_spec:

use_sens
--------

Type: :term:`bool <bool>`

Option to use sensitivity equations in ode solver.

Example:-

.. code-block:: pyml

    use_sens: True


.. _sim-ode_solver-scipy_odeint_spec:

SCIPY_ODEINT
============

Type: :term:`dict_record <dict_record>`

odeint solver record

Example:-

.. code-block:: pyml

    SCIPY_ODEINT:
        atol: 1e-06
        rtol: 1e-06
        max_nsteps: 10000000
        use_supersections: auto
        use_jacobian: False
        use_sens: True
        use_tcrit: False


.. _sim-ode_solver-scipy_odeint-atol_spec:

atol
----

Type: :term:`float <float>`

Absolute tolerance of ode solver.

Example:-

.. code-block:: pyml

    atol: 1e-06


.. _sim-ode_solver-scipy_odeint-rtol_spec:

rtol
----

Type: :term:`float <float>`

Relative tolerance of ode solver.

Example:-

.. code-block:: pyml

    rtol: 1e-06


.. _sim-ode_solver-scipy_odeint-max_nsteps_spec:

max_nsteps
----------

Type: :term:`int <int>`

Maximum number of steps allowed in ode solver.

Example:-

.. code-block:: pyml

    max_nsteps: 10000000


.. _sim-ode_solver-scipy_odeint-use_supersections_spec:

use_supersections
-----------------

Type: :term:`bool <bool>` / :term:`auto <auto>`

Option to combine sections into supersections, which can make PoPy run faster, however with discontinuous ODE params you may need to turn this off (closer to nonmem approach).

Example:-

.. code-block:: pyml

    use_supersections: auto


.. _sim-ode_solver-scipy_odeint-use_jacobian_spec:

use_jacobian
------------

Type: :term:`bool <bool>`

Option to use jacobian in ode solver.

Example:-

.. code-block:: pyml

    use_jacobian: False


.. _sim-ode_solver-scipy_odeint-use_sens_spec:

use_sens
--------

Type: :term:`bool <bool>`

Option to use sensitivity equations in ode solver.

Example:-

.. code-block:: pyml

    use_sens: True


.. _sim-ode_solver-scipy_odeint-use_tcrit_spec:

use_tcrit
---------

Type: :term:`bool <bool>`

Option to set lsoda tcrit to start and end of subsection. Note this is an experimental option.

Example:-

.. code-block:: pyml

    use_tcrit: False


.. _sim-ode_solver-cppode_spec:

CPPODE
======

Type: :term:`dict_record <dict_record>`

C++ version of original cvode c library.

Example:-

.. code-block:: pyml

    CPPODE:
        atol: 1e-06
        rtol: 1e-06
        max_nsteps: 10000000
        use_supersections: auto
        use_sens: True


.. _sim-ode_solver-cppode-atol_spec:

atol
----

Type: :term:`float <float>`

Absolute tolerance of ode solver.

Example:-

.. code-block:: pyml

    atol: 1e-06


.. _sim-ode_solver-cppode-rtol_spec:

rtol
----

Type: :term:`float <float>`

Relative tolerance of ode solver.

Example:-

.. code-block:: pyml

    rtol: 1e-06


.. _sim-ode_solver-cppode-max_nsteps_spec:

max_nsteps
----------

Type: :term:`int <int>`

Maximum number of steps allowed in ode solver.

Example:-

.. code-block:: pyml

    max_nsteps: 10000000


.. _sim-ode_solver-cppode-use_supersections_spec:

use_supersections
-----------------

Type: :term:`bool <bool>` / :term:`auto <auto>`

Option to combine sections into supersections, which can make PoPy run faster, however with discontinuous ODE params you may need to turn this off (closer to nonmem approach).

Example:-

.. code-block:: pyml

    use_supersections: auto


.. _sim-ode_solver-cppode-use_sens_spec:

use_sens
--------

Type: :term:`bool <bool>`

Option to use sensitivity equations in ode solver.

Example:-

.. code-block:: pyml

    use_sens: True


.. _sim-ode_solver-cpplsoda_spec:

CPPLSODA
========

Type: :term:`dict_record <dict_record>`

C++ version of original cvode c library.

Example:-

.. code-block:: pyml

    CPPLSODA:
        atol: 1e-06
        rtol: 1e-06
        max_nsteps: 10000000
        use_supersections: auto
        use_sens: True
        hmin: 1e-12


.. _sim-ode_solver-cpplsoda-atol_spec:

atol
----

Type: :term:`float <float>`

Absolute tolerance of ode solver.

Example:-

.. code-block:: pyml

    atol: 1e-06


.. _sim-ode_solver-cpplsoda-rtol_spec:

rtol
----

Type: :term:`float <float>`

Relative tolerance of ode solver.

Example:-

.. code-block:: pyml

    rtol: 1e-06


.. _sim-ode_solver-cpplsoda-max_nsteps_spec:

max_nsteps
----------

Type: :term:`int <int>`

Maximum number of steps allowed in ode solver.

Example:-

.. code-block:: pyml

    max_nsteps: 10000000


.. _sim-ode_solver-cpplsoda-use_supersections_spec:

use_supersections
-----------------

Type: :term:`bool <bool>` / :term:`auto <auto>`

Option to combine sections into supersections, which can make PoPy run faster, however with discontinuous ODE params you may need to turn this off (closer to nonmem approach).

Example:-

.. code-block:: pyml

    use_supersections: auto


.. _sim-ode_solver-cpplsoda-use_sens_spec:

use_sens
--------

Type: :term:`bool <bool>`

Option to use sensitivity equations in ode solver.

Example:-

.. code-block:: pyml

    use_sens: True


.. _sim-ode_solver-cpplsoda-hmin_spec:

hmin
----

Type: :term:`float <float>`

Minimum step size of ode solver.

Example:-

.. code-block:: pyml

    hmin: 1e-12


.. _sim-output_options_spec:

OUTPUT_OPTIONS
**************

Type: :term:`dict_record <dict_record>`

Output options for sim_script

Example:-

.. code-block:: pyml

    OUTPUT_OPTIONS:
        sim_time_step: -1.0


.. _sim-output_options-sim_time_step_spec:

sim_time_step
=============

Type: :term:`float <float>`

Size of time step when creating smooth curve predictions
note setting this to a negative value, results in
simulated predictions for each individual 
ONLY at time points in the original data set.

Example:-

.. code-block:: pyml

    sim_time_step: -1.0


.. _sim-output_scripts_spec:

OUTPUT_SCRIPTS
**************

Type: :term:`dict_record <dict_record>`

scripts to output for further processing

Example:-

.. code-block:: pyml

    OUTPUT_SCRIPTS:
        GRPH:
            output_mode: none
            grph_list: ['SPAG_GRPH']
            x_var: TIME
            x_axis_label: TIME
            y_var_list: ['DV_CENTRAL_sim', 'DV_CENTRAL']
            y_var_src_list: ['sim', 'orig']
            y_var_label_list: ['Drug conc. (units)', 'Drug conc. (units)']
            split_field: none
            share_axes: False
            y_scale: linear


.. _sim-output_scripts-grph_spec:

GRPH
====

Type: :term:`dict_record <dict_record>`

Options to pass to plt_grph_script.

Example:-

.. code-block:: pyml

    GRPH:
        output_mode: none
        grph_list: ['SPAG_GRPH']
        x_var: TIME
        x_axis_label: TIME
        y_var_list: ['DV_CENTRAL_sim', 'DV_CENTRAL']
        y_var_src_list: ['sim', 'orig']
        y_var_label_list: ['Drug conc. (units)', 'Drug conc. (units)']
        split_field: none
        share_axes: False
        y_scale: linear


.. _sim-output_scripts-grph-output_mode_spec:

output_mode
-----------

Type: :term:`one_of(none,create,run) <one_of>`

Output options.

Example:-

.. code-block:: pyml

    output_mode: none


.. _sim-output_scripts-grph-grph_list_spec:

grph_list
---------

Type: :term:`list(str) <list>`

List of graph types to generate in popy_grph script.

Example:-

.. code-block:: pyml

    grph_list: ['SPAG_GRPH']


.. _sim-output_scripts-grph-x_var_spec:

x_var
-----

Type: :term:`str <str>`

x axis variable name.

Example:-

.. code-block:: pyml

    x_var: TIME


.. _sim-output_scripts-grph-x_axis_label_spec:

x_axis_label
------------

Type: :term:`str <str>`

x axis label

Example:-

.. code-block:: pyml

    x_axis_label: TIME


.. _sim-output_scripts-grph-y_var_list_spec:

y_var_list
----------

Type: :term:`list(str) <list>`

List of y variable names to be plotted on graph.

Example:-

.. code-block:: pyml

    y_var_list: ['DV_CENTRAL_sim', 'DV_CENTRAL']


.. _sim-output_scripts-grph-y_var_src_list_spec:

y_var_src_list
--------------

Type: :term:`list(str) <list>`

Source of data has to be either sim or orig

Example:-

.. code-block:: pyml

    y_var_src_list: ['sim', 'orig']


.. _sim-output_scripts-grph-y_var_label_list_spec:

y_var_label_list
----------------

Type: :term:`list(str) <list>`

List of y variable labels to be plotted on graph.

Example:-

.. code-block:: pyml

    y_var_label_list: ['Drug conc. (units)', 'Drug conc. (units)']


.. _sim-output_scripts-grph-split_field_spec:

split_field
-----------

Type: :term:`str <str>`

field in c[X] data use each value to split data.

Example:-

.. code-block:: pyml

    split_field: none


.. _sim-output_scripts-grph-share_axes_spec:

share_axes
----------

Type: :term:`bool <bool>`

Option to share axes between individuals when plotting
graphical data

Example:-

.. code-block:: pyml

    share_axes: False


.. _sim-output_scripts-grph-y_scale_spec:

y_scale
-------

Type: :term:`one_of(linear,log) <one_of>`

y axis scale - can be either 'linear' or 'log'.

Example:-

.. code-block:: pyml

    y_scale: linear



