METHOD_OPTIONS¶
Type: dict_record
method options for mtut_script
Example:-
METHOD_OPTIONS:
py_module: mtut
rand_seed: 12345
float_format: default
py_module¶
Type: one_of(mtut)
Python module required to process this script file
Example:-
py_module: mtut
rand_seed¶
Option to set seed to make run result reproducible -e.g. when debugging.
Example:-
rand_seed: 12345
PARALLEL¶
Type: one_of_record
one of many possible servers
Example:-
PARALLEL:
SINGLE: {}
MPI_WORKERS¶
Type: dict_record
MPI local server spec.
Example:-
MPI_WORKERS:
n_workers: auto
cpu_load: 1.0
n_workers¶
Number of workers to use on this machine, defaults to number of processors, but could be more or fewer.
Example:-
n_workers: auto
DESCRIPTION¶
Type: dict_record
Description fields for script.
Example:-
DESCRIPTION:
name: my_pkpd_model
title: My PKPD model
author: My Name
abstract: |
Abstract describing the model
keywords: ['pkpd']
FILE_PATHS¶
Type: dict_record
file paths
Example:-
FILE_PATHS:
output_folder: auto
log_folder: auto
output_file_ext: ['svg']
delete_old_files_flag: False
output_iteration_results: True
output_folder¶
Type: output_folder / auto
Output folder - results of computation stored here
Example:-
output_folder: auto
log_folder¶
Type: output_folder / auto
Log folder - log files stored here
Example:-
log_folder: auto
output_file_ext¶
Type: list_of(pdf,png,svg)
Output file extension - determines graphical output file format.
Example:-
output_file_ext: ['svg']
DATA_FIELDS¶
Type: dict_record
data fields for popy.dat.fields object
Example:-
DATA_FIELDS:
type_field: TYPE
id_field: ID
time_field: TIME
type_field¶
Type: str
Field name in data file that contains row type info, e.g. obs/dose etc
Example:-
type_field: TYPE
GEN_EFFECTS¶
Type: repeat_verb_record
GEN_EFFECT params to define hierarchical population model
Example:-
GEN_EFFECTS:
POP: |
c[AMT] = 100.0
f[KA] = 0.2
f[CL] = 2.0
f[V1] = 50
f[Q] = 1.0
f[V2] = 80
f[KA_isv,CL_isv,V1_isv,Q_isv,V2_isv] = [
[0.1],
[0.01, 0.03],
[0.01, -0.01, 0.09],
[0.01, 0.02, 0.01, 0.07],
[0.01, 0.02, 0.01, 0.01, 0.05],
]
f[PNOISE] = 0.15
ID: |
c[ID] = sequential(50)
t[DOSE] = 2.0
t[OBS] ~ unif(1.0, 50.0; 5)
# t[OBS] = range(1.0, 50.0; 5)
r[KA, CL, V1, Q, V2] ~ mnorm([0,0,0,0,0], f[KA_isv,CL_isv,V1_isv,Q_isv,V2_isv])
FIT_EFFECTS¶
Type: repeat_verb_record
FIT_EFFECT params to define hierarchical population model
Example:-
FIT_EFFECTS:
POP: |
f[KA] ~ P1.0
f[CL] ~ P1.0
f[V1] ~ P20
f[Q] ~ P0.5
f[V2] ~ P100
f[KA_isv,CL_isv,V1_isv,Q_isv,V2_isv] ~ spd_matrix() [
[0.05],
[0.01, 0.05],
[0.01, 0.01, 0.05],
[0.01, 0.01, 0.01, 0.05],
[0.01, 0.01, 0.01, 0.01, 0.05],
]
f[PNOISE] ~ P0.1
ID: |
r[KA, CL, V1, Q, V2] ~ mnorm([0,0,0,0,0], f[KA_isv,CL_isv,V1_isv,Q_isv,V2_isv])
PREPROCESS¶
Type: verbatim
Code that preprocesses the input data. Use this to filter rows and create derived covariates.
Example:-
PREPROCESS: |
MODEL_PARAMS¶
Type: verbatim
Defines the mapping from c[X], f[X] and r[X] variables to individual model m[X] parameters.
Example:-
MODEL_PARAMS: |
m[KA] = f[KA] * exp(r[KA])
m[CL] = f[CL] * exp(r[CL])
m[V1] = f[V1] * exp(r[V1])
m[Q] = f[Q] * exp(r[Q])
m[V2] = f[V2] * exp(r[V2])
m[ANOISE] = 0.001
m[PNOISE] = f[PNOISE]
STATES¶
Type: verbatim
Optional section for setting initial values of s[X] variables can also set slabel[X] text labels.
Example:-
STATES: |
DERIVATIVES¶
Type: verbatim
Define how the covariates and effects determine flows between compartments.
Example:-
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]
PREDICTIONS¶
Type: verbatim
Define the final predicted m[X] variables to be output by the compartment model system.
Example:-
PREDICTIONS: |
p[DV_CENTRAL] = s[CENTRAL]/m[V1]
plabel[DV_CENTRAL] = 'Drug conc. (units)'
var = m[ANOISE]**2 + m[PNOISE]**2 * p[DV_CENTRAL]**2
c[DV_CENTRAL] ~ norm(p[DV_CENTRAL], var)
ODE_SOLVER¶
Type: one_of_record
one of many possible solvers
Example:-
ODE_SOLVER:
CPPLSODA:
atol: 1e-06
rtol: 1e-06
max_nsteps: 10000000
use_supersections: True
use_sens: False
hmin: 0.0
ANALYTIC¶
Type: dict_record
Analytic method for solving ODE
Example:-
ANALYTIC:
use_supersections: auto
use_sens: True
use_supersections¶
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:-
use_supersections: auto
SCIPY_ODEINT¶
Type: dict_record
odeint solver record
Example:-
SCIPY_ODEINT:
atol: 1e-06
rtol: 1e-06
max_nsteps: 10000000
use_supersections: auto
use_jacobian: False
use_sens: True
use_tcrit: False
use_supersections¶
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:-
use_supersections: auto
CPPLSODA¶
Type: dict_record
C++ version of original cvode c library.
Example:-
CPPLSODA:
atol: 1e-06
rtol: 1e-06
max_nsteps: 10000000
use_supersections: auto
use_sens: True
hmin: 1e-12
use_supersections¶
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:-
use_supersections: auto
FIT_METHODS¶
Type: list_record
one of many possible fitters
Example:-
FIT_METHODS:
- JOE:
ODE_SOLVER: {INHERIT: {}}
output_timing_flag: False
output_warning_detail_flag: True
max_n_main_iterations: 30
CONVERGER: {OBJ_INC: {}}
use_laplacian: False
use_chain: True
use_lm_jac: True
reset_re_flag: True
JOE¶
Type: dict_record
Joint Optimisation and Estimation method
Example:-
JOE:
ODE_SOLVER: {INHERIT: {}}
output_timing_flag: False
output_warning_detail_flag: True
max_n_main_iterations: 50
CONVERGER: {OBJ_INC: {}}
use_laplacian: False
use_chain: True
use_lm_jac: True
reset_re_flag: True
output_warning_detail_flag¶
Type: bool
Option to output warning detail.
Example:-
output_warning_detail_flag: True
use_laplacian¶
Type: bool
Option to use full laplacian to compute hessian in objective function term4, this is much slower than using the expectation of the outer product of the jacobian
Example:-
use_laplacian: False
use_chain¶
Type: bool
Option to use chain rule when computing derivatives.
Example:-
use_chain: True
ND¶
Type: dict_record
None Derivative Optimisation method
Example:-
ND:
ODE_SOLVER: {INHERIT: {}}
output_timing_flag: False
output_warning_detail_flag: True
max_n_main_iterations: 50
CONVERGER: {OBJ_INC: {}}
use_laplacian: False
use_chain: True
use_lm_jac: True
reset_re_flag: True
central_diff_switch_flag: True
var_fx_bobyqa_opt_flag: True
output_warning_detail_flag¶
Type: bool
Option to output warning detail.
Example:-
output_warning_detail_flag: True
use_laplacian¶
Type: bool
Option to use full laplacian to compute hessian in objective function term4, this is much slower than using the expectation of the outer product of the jacobian
Example:-
use_laplacian: False
use_chain¶
Type: bool
Option to use chain rule when computing derivatives.
Example:-
use_chain: True
use_lm_jac¶
Type: bool
Option to use custom jacobian when optimising r[X] using L-M.
Example:-
use_lm_jac: True
reset_re_flag¶
Type: bool
Reset r[X]=0.0 before each r[X] optimisation
Example:-
reset_re_flag: True
FOCE¶
Type: dict_record
First order conditional estimation method
Example:-
FOCE:
ODE_SOLVER: {INHERIT: {}}
output_timing_flag: False
output_warning_detail_flag: True
max_n_main_iterations: 50
CONVERGER: {OBJ_INC: {}}
use_laplacian: False
use_chain: True
use_lm_jac: True
reset_re_flag: True
central_diff_switch_flag: True
output_warning_detail_flag¶
Type: bool
Option to output warning detail.
Example:-
output_warning_detail_flag: True
use_laplacian¶
Type: bool
Option to use full laplacian to compute hessian in objective function term4, this is much slower than using the expectation of the outer product of the jacobian
Example:-
use_laplacian: False
use_chain¶
Type: bool
Option to use chain rule when computing derivatives.
Example:-
use_chain: True
use_lm_jac¶
Type: bool
Option to use custom jacobian when optimising r[X] using L-M.
Example:-
use_lm_jac: True
COVARIANCE¶
Type: one_of_record
Covariance methods used to estimate standard errors.
Example:-
COVARIANCE:
NO_COVARIANCE: {}
NO_COVARIANCE¶
Type: dict_record
Do NOT compute covariance matrix and standard errors.
Example:-
NO_COVARIANCE: {}
SANDWICH¶
Type: dict_record
Use sandwich operator to estimate covariance matrix.
Example:-
SANDWICH:
var_covariance_flag: False
inv_hessian_flag: False
var_covariance_flag¶
Type: bool
Optionally compute standard errors for f[X] covariance elements this could take a long time for large covariance matrices. Note the results of the standard error computation for the main f[X] parameters combined with the variances will be different.
Example:-
var_covariance_flag: False
NONMEM¶
Type: dict_record
Use sandwich operator to estimate covariance matrix.
Example:-
NONMEM:
var_covariance_flag: False
inv_hessian_flag: False
var_covariance_flag¶
Type: bool
Optionally compute standard errors for f[X] covariance elements this could take a long time for large covariance matrices. Note the results of the standard error computation for the main f[X] parameters combined with the variances will be different.
Example:-
var_covariance_flag: False
OUTPUT_SCRIPTS¶
Type: dict_record
Scripts to output for further processing.
Example:-
OUTPUT_SCRIPTS:
MGEN: {output_mode: run}
MFIT: {output_mode: run}
MCOMP: {output_mode: run, dot_size: 12}
MCOMP¶
Type: dict_record
options to pass to mcomp script.
Example:-
MCOMP:
output_mode: none
dot_size: 12