:orphan: 





.. _gen_diag_fit_diag_fit:



Diagonal matrix generation diagonal matrix fit
##############################################

[Generated automatically as a Fitting summary]

Inputs
******



Description
===========

:Name: gen_diag_fit_diag

:Title: Diagonal matrix generation diagonal matrix fit

:Author: Wright Dose Ltd

:Abstract: 

| One compartment model with absorption compartment and CL/V parametrisation.
| This script uses a diagonal covariance matrix to generate the data and a diagonal covariance matrix to fit.

:Keywords: one compartment model; dep_one_cmp_cl; diagonal matrix

:Input Script: :download:`gen_diag_fit_diag_fit.pyml <gen_diag_fit_diag_fit.pyml>`

:Input Data: :download:`synthetic_data.csv <synthetic_data.csv>`

:Diagram: 


.. thumbnail:: gen_diag_fit_diag_fit.pyml_output/fit/compartment_diagram.svg
    :width: 200px


Initial fixed effect estimates
==============================

.. code-block:: pyml

    f[KA] = 0.3000
    f[CL] = 3.0000
    f[V] = 20.0000
    f[PNOISE_STD] = 0.1000
    f[ANOISE_STD] = 0.0500
    f[CL_isv,V_isv] = [
        [ 0.0100, 0.0000 ],
        [ 0.0000, 0.0100 ],
    ]



Outputs
*******



Final objective value
=====================

.. code-block:: pyml

    -2215.9658


which required 1.9 iterations and took 1096.61 seconds

Final fitted fixed effects
==========================

.. code-block:: pyml

    f[KA] = 0.3000
    f[CL] = 3.0000
    f[V] = 20.0000
    f[PNOISE_STD] = 0.1000
    f[ANOISE_STD] = 0.0500
    f[CL_isv,V_isv] = [
        [ 0.1977, 0.0000 ],
        [ 0.0000, 0.1167 ],
    ]



Fitted parameter .csv files
===========================


:Fixed Effects: :download:`fx_params.csv (fit) <gen_diag_fit_diag_fit.pyml_output/fit/solN/fx_params.csv>`

:Random Effects: :download:`rx_params.csv (fit) <gen_diag_fit_diag_fit.pyml_output/fit/solN/rx_params.csv>`

:Model params: :download:`mx_params.csv (fit) <gen_diag_fit_diag_fit.pyml_output/fit/solN/mx_params.csv>`

:State values: :download:`sx_params.csv (fit) <gen_diag_fit_diag_fit.pyml_output/fit/solN/sx_params.csv>`

:Predictions: :download:`px_params.csv (fit) <gen_diag_fit_diag_fit.pyml_output/fit/solN/px_params.csv>`



Plots
*****



Dense sim plots
===============



.. thumbnail:: images/fit_dense/000001.svg
    :width: 200px


.. thumbnail:: images/fit_dense/000002.svg
    :width: 200px


.. thumbnail:: images/fit_dense/000003.svg
    :width: 200px


Alternatively see :ref:`gen_diag_fit_diag_dense_sim_plots`

Comparison
**********



Compare Main f[X]
=================




Compare Noise f[X]
==================




Compare Variance f[X]
=====================


===============  ================  ==============  =============  ============
Variable Name      Starting Value    Fitted Value    Prop Change    Abs Change
===============  ================  ==============  =============  ============
f[CL_isv]                  0.0100          0.1977        18.7722        0.1877
f[CL_isv;V_isv]            0.0000          0.0000       INF             0.0000
f[V_isv;CL_isv]            0.0000          0.0000       INF             0.0000
f[V_isv]                   0.0100          0.1167        10.6701        0.1067
===============  ================  ==============  =============  ============