1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
|
<!-- Generated by pkgdown: do not edit by hand -->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Fit a kinetic model to data with one or more state variables — mkinfit • mkin</title>
<!-- jquery -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js" integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8=" crossorigin="anonymous"></script>
<!-- Bootstrap -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha256-916EbMg70RQy9LHiGkXzG8hSg9EdNy97GazNG/aiY1w=" crossorigin="anonymous" />
<script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha256-U5ZEeKfGNOja007MMD3YBI0A3OSZOQbeG6z2f2Y0hu8=" crossorigin="anonymous"></script>
<!-- Font Awesome icons -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" integrity="sha256-eZrrJcwDc/3uDhsdt61sL2oOBY362qM3lon1gyExkL0=" crossorigin="anonymous" />
<!-- clipboard.js -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.4/clipboard.min.js" integrity="sha256-FiZwavyI2V6+EXO1U+xzLG3IKldpiTFf3153ea9zikQ=" crossorigin="anonymous"></script>
<!-- sticky kit -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/sticky-kit/1.1.3/sticky-kit.min.js" integrity="sha256-c4Rlo1ZozqTPE2RLuvbusY3+SU1pQaJC0TjuhygMipw=" crossorigin="anonymous"></script>
<!-- pkgdown -->
<link href="../pkgdown.css" rel="stylesheet">
<script src="../pkgdown.js"></script>
<meta property="og:title" content="Fit a kinetic model to data with one or more state variables — mkinfit" />
<meta property="og:description" content="This function maximises the likelihood of the observed data using
the Port algorithm nlminb, and the specified initial or fixed
parameters and starting values. In each step of the optimsation, the kinetic
model is solved using the function mkinpredict. The parameters
of the selected error model are fitted simultaneously with the degradation
model parameters, as both of them are arguments of the likelihood function.
Per default, parameters in the kinetic models are internally transformed in
order to better satisfy the assumption of a normal distribution of their
estimators." />
<meta name="twitter:card" content="summary" />
<!-- mathjax -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/MathJax.js" integrity="sha256-nvJJv9wWKEm88qvoQl9ekL2J+k/RWIsaSScxxlsrv8k=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/config/TeX-AMS-MML_HTMLorMML.js" integrity="sha256-84DKXVJXs0/F8OTMzX4UR909+jtl4G7SPypPavF+GfA=" crossorigin="anonymous"></script>
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
</head>
<body>
<div class="container template-reference-topic">
<header>
<div class="navbar navbar-default navbar-fixed-top" role="navigation">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<span class="navbar-brand">
<a class="navbar-link" href="../index.html">mkin</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.9.49.4</span>
</span>
</div>
<div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav">
<li>
<a href="../reference/index.html">Functions and data</a>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">
Articles
<span class="caret"></span>
</a>
<ul class="dropdown-menu" role="menu">
<li>
<a href="../articles/mkin.html">Introduction to mkin</a>
</li>
<li>
<a href="../articles/FOCUS_D.html">Example evaluation of FOCUS Example Dataset D</a>
</li>
<li>
<a href="../articles/FOCUS_L.html">Example evaluation of FOCUS Laboratory Data L1 to L3</a>
</li>
<li>
<a href="../articles/web_only/FOCUS_Z.html">Example evaluation of FOCUS Example Dataset Z</a>
</li>
<li>
<a href="../articles/web_only/compiled_models.html">Performance benefit by using compiled model definitions in mkin</a>
</li>
<li>
<a href="../articles/twa.html">Calculation of time weighted average concentrations with mkin</a>
</li>
<li>
<a href="../articles/web_only/NAFTA_examples.html">Example evaluation of NAFTA SOP Attachment examples</a>
</li>
</ul>
</li>
<li>
<a href="../news/index.html">News</a>
</li>
</ul>
<ul class="nav navbar-nav navbar-right">
</ul>
</div><!--/.nav-collapse -->
</div><!--/.container -->
</div><!--/.navbar -->
</header>
<div class="row">
<div class="col-md-9 contents">
<div class="page-header">
<h1>Fit a kinetic model to data with one or more state variables</h1>
<div class="hidden name"><code>mkinfit.Rd</code></div>
</div>
<div class="ref-description">
<p>This function maximises the likelihood of the observed data using
the Port algorithm <code><a href='https://www.rdocumentation.org/packages/stats/topics/nlminb'>nlminb</a></code>, and the specified initial or fixed
parameters and starting values. In each step of the optimsation, the kinetic
model is solved using the function <code><a href='mkinpredict.html'>mkinpredict</a></code>. The parameters
of the selected error model are fitted simultaneously with the degradation
model parameters, as both of them are arguments of the likelihood function.</p>
<p>Per default, parameters in the kinetic models are internally transformed in
order to better satisfy the assumption of a normal distribution of their
estimators.</p>
</div>
<pre class="usage"><span class='fu'>mkinfit</span>(<span class='no'>mkinmod</span>, <span class='no'>observed</span>,
<span class='kw'>parms.ini</span> <span class='kw'>=</span> <span class='st'>"auto"</span>,
<span class='kw'>state.ini</span> <span class='kw'>=</span> <span class='st'>"auto"</span>,
<span class='kw'>err.ini</span> <span class='kw'>=</span> <span class='st'>"auto"</span>,
<span class='kw'>fixed_parms</span> <span class='kw'>=</span> <span class='kw'>NULL</span>, <span class='kw'>fixed_initials</span> <span class='kw'>=</span> <span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/names'>names</a></span>(<span class='no'>mkinmod</span>$<span class='no'>diffs</span>)[-<span class='fl'>1</span>],
<span class='kw'>from_max_mean</span> <span class='kw'>=</span> <span class='fl'>FALSE</span>,
<span class='kw'>solution_type</span> <span class='kw'>=</span> <span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/c'>c</a></span>(<span class='st'>"auto"</span>, <span class='st'>"analytical"</span>, <span class='st'>"eigen"</span>, <span class='st'>"deSolve"</span>),
<span class='kw'>method.ode</span> <span class='kw'>=</span> <span class='st'>"lsoda"</span>,
<span class='kw'>use_compiled</span> <span class='kw'>=</span> <span class='st'>"auto"</span>,
<span class='kw'>control</span> <span class='kw'>=</span> <span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/list'>list</a></span>(<span class='kw'>eval.max</span> <span class='kw'>=</span> <span class='fl'>300</span>, <span class='kw'>iter.max</span> <span class='kw'>=</span> <span class='fl'>200</span>),
<span class='kw'>transform_rates</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>,
<span class='kw'>transform_fractions</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>,
<span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>FALSE</span>,
<span class='kw'>atol</span> <span class='kw'>=</span> <span class='fl'>1e-8</span>, <span class='kw'>rtol</span> <span class='kw'>=</span> <span class='fl'>1e-10</span>, <span class='kw'>n.outtimes</span> <span class='kw'>=</span> <span class='fl'>100</span>,
<span class='kw'>error_model</span> <span class='kw'>=</span> <span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/c'>c</a></span>(<span class='st'>"const"</span>, <span class='st'>"obs"</span>, <span class='st'>"tc"</span>),
<span class='kw'>trace_parms</span> <span class='kw'>=</span> <span class='fl'>FALSE</span>, <span class='no'>...</span>)</pre>
<h2 class="hasAnchor" id="arguments"><a class="anchor" href="#arguments"></a>Arguments</h2>
<table class="ref-arguments">
<colgroup><col class="name" /><col class="desc" /></colgroup>
<tr>
<th>mkinmod</th>
<td><p>A list of class <code><a href='mkinmod.html'>mkinmod</a></code>, containing the kinetic model to be
fitted to the data, or one of the shorthand names ("SFO", "FOMC", "DFOP",
"HS", "SFORB", "IORE"). If a shorthand name is given, a parent only degradation
model is generated for the variable with the highest value in
<code>observed</code>.</p></td>
</tr>
<tr>
<th>observed</th>
<td><p>A dataframe with the observed data. The first column called "name" must
contain the name of the observed variable for each data point. The second
column must contain the times of observation, named "time". The third
column must be named "value" and contain the observed values. Zero values
in the "value" column will be removed, with a warning, in order to
avoid problems with fitting the two-component error model. This is not
expected to be a problem, because in general, values of zero are not
observed in degradation data, because there is a lower limit of detection.</p></td>
</tr>
<tr>
<th>parms.ini</th>
<td><p>A named vector of initial values for the parameters, including parameters
to be optimised and potentially also fixed parameters as indicated by
<code>fixed_parms</code>. If set to "auto", initial values for rate constants
are set to default values. Using parameter names that are not in the model
gives an error.</p>
<p>It is possible to only specify a subset of the parameters that the model
needs. You can use the parameter lists "bparms.ode" from a previously
fitted model, which contains the differential equation parameters from this
model. This works nicely if the models are nested. An example is given
below.</p></td>
</tr>
<tr>
<th>state.ini</th>
<td><p>A named vector of initial values for the state variables of the model. In
case the observed variables are represented by more than one model
variable, the names will differ from the names of the observed variables
(see <code>map</code> component of <code><a href='mkinmod.html'>mkinmod</a></code>). The default is to set
the initial value of the first model variable to the mean of the time zero
values for the variable with the maximum observed value, and all others to 0.
If this variable has no time zero observations, its initial value is set to 100.</p></td>
</tr>
<tr>
<th>err.ini</th>
<td><p>A named vector of initial values for the error model parameters to be
optimised. If set to "auto", initial values are set to default values.
Otherwise, inital values for all error model parameters must be
given.</p></td>
</tr>
<tr>
<th>fixed_parms</th>
<td><p>The names of parameters that should not be optimised but rather kept at the
values specified in <code>parms.ini</code>.</p></td>
</tr>
<tr>
<th>fixed_initials</th>
<td><p>The names of model variables for which the initial state at time 0 should
be excluded from the optimisation. Defaults to all state variables except
for the first one.</p></td>
</tr>
<tr>
<th>from_max_mean</th>
<td><p>If this is set to TRUE, and the model has only one observed variable, then
data before the time of the maximum observed value (after averaging for each
sampling time) are discarded, and this time is subtracted from all
remaining time values, so the time of the maximum observed mean value is
the new time zero.</p></td>
</tr>
<tr>
<th>solution_type</th>
<td><p>If set to "eigen", the solution of the system of differential equations is
based on the spectral decomposition of the coefficient matrix in cases that
this is possible. If set to "deSolve", a numerical ode solver from package
<code>deSolve</code> is used. If set to "analytical", an analytical
solution of the model is used. This is only implemented for simple
degradation experiments with only one state variable, i.e. with no
metabolites. The default is "auto", which uses "analytical" if possible,
otherwise "deSolve" if a compiler is present, and "eigen" if no
compiler is present and the model can be expressed using eigenvalues and
eigenvectors. This argument is passed on to the helper function
<code><a href='mkinpredict.html'>mkinpredict</a></code>.</p></td>
</tr>
<tr>
<th>method.ode</th>
<td><p>The solution method passed via <code><a href='mkinpredict.html'>mkinpredict</a></code> to
<code>ode</code> in case the solution type is "deSolve". The default
"lsoda" is performant, but sometimes fails to converge.</p></td>
</tr>
<tr>
<th>use_compiled</th>
<td><p>If set to <code>FALSE</code>, no compiled version of the <code><a href='mkinmod.html'>mkinmod</a></code>
model is used in the calls to <code><a href='mkinpredict.html'>mkinpredict</a></code> even if a compiled
version is present.</p></td>
</tr>
<tr>
<th>control</th>
<td><p>A list of control arguments passed to <code><a href='https://www.rdocumentation.org/packages/stats/topics/nlminb'>nlminb</a></code>.</p></td>
</tr>
<tr>
<th>transform_rates</th>
<td><p>Boolean specifying if kinetic rate constants should be transformed in the
model specification used in the fitting for better compliance with the
assumption of normal distribution of the estimator. If TRUE, also
alpha and beta parameters of the FOMC model are log-transformed, as well
as k1 and k2 rate constants for the DFOP and HS models and the break point
tb of the HS model. If FALSE, zero is used as a lower bound for the rates
in the optimisation.</p></td>
</tr>
<tr>
<th>transform_fractions</th>
<td><p>Boolean specifying if formation fractions constants should be transformed in the
model specification used in the fitting for better compliance with the
assumption of normal distribution of the estimator. The default (TRUE) is
to do transformations. If TRUE, the g parameter of the DFOP and HS
models are also transformed, as they can also be seen as compositional
data. The transformation used for these transformations is the
<code><a href='ilr.html'>ilr</a></code> transformation.</p></td>
</tr>
<tr>
<th>quiet</th>
<td><p>Suppress printing out the current value of the negative log-likelihood
after each improvement?</p></td>
</tr>
<tr>
<th>atol</th>
<td><p>Absolute error tolerance, passed to <code>ode</code>. Default is 1e-8,
lower than in <code>lsoda</code>.</p></td>
</tr>
<tr>
<th>rtol</th>
<td><p>Absolute error tolerance, passed to <code>ode</code>. Default is 1e-10,
much lower than in <code>lsoda</code>.</p></td>
</tr>
<tr>
<th>n.outtimes</th>
<td><p>The length of the dataseries that is produced by the model prediction
function <code><a href='mkinpredict.html'>mkinpredict</a></code>. This impacts the accuracy of
the numerical solver if that is used (see <code>solution_type</code> argument.
The default value is 100.</p></td>
</tr>
<tr>
<th>error_model</th>
<td><p>If the error model is "const", a constant standard deviation
is assumed.</p>
<p>If the error model is "obs", each observed variable is assumed to have its
own variance.</p>
<p>If the error model is "tc" (two-component error model), a two component
error model similar to the one described by Rocke and Lorenzato (1995) is
used for setting up the likelihood function. Note that this model deviates
from the model by Rocke and Lorenzato, as their model implies that the
errors follow a lognormal distribution for large values, not a normal
distribution as assumed by this method.</p></td>
</tr>
<tr>
<th>trace_parms</th>
<td><p>Should a trace of the parameter values be listed?</p></td>
</tr>
<tr>
<th>…</th>
<td><p>Further arguments that will be passed on to <code>deSolve</code>.</p></td>
</tr>
</table>
<h2 class="hasAnchor" id="value"><a class="anchor" href="#value"></a>Value</h2>
<p>A list with "mkinfit" in the class attribute. A summary can be obtained by
<code><a href='summary.mkinfit.html'>summary.mkinfit</a></code>.</p>
<h2 class="hasAnchor" id="see-also"><a class="anchor" href="#see-also"></a>See also</h2>
<div class='dont-index'><p>Plotting methods <code><a href='plot.mkinfit.html'>plot.mkinfit</a></code> and <code><a href='mkinparplot.html'>mkinparplot</a></code>.</p>
<p>Comparisons of models fitted to the same data can be made using <code><a href='https://www.rdocumentation.org/packages/stats/topics/AIC'>AIC</a></code>
by virtue of the method <code><a href='logLik.mkinfit.html'>logLik.mkinfit</a></code>.</p>
<p>Fitting of several models to several datasets in a single call to
<code><a href='mmkin.html'>mmkin</a></code>.</p></div>
<h2 class="hasAnchor" id="note"><a class="anchor" href="#note"></a>Note</h2>
<p>When using the "IORE" submodel for metabolites, fitting with
"transform_rates = TRUE" (the default) often leads to failures of the
numerical ODE solver. In this situation it may help to switch off the
internal rate transformation.</p>
<h2 class="hasAnchor" id="source"><a class="anchor" href="#source"></a>Source</h2>
<p>Rocke, David M. und Lorenzato, Stefan (1995) A two-component model for
measurement error in analytical chemistry. Technometrics 37(2), 176-184.</p>
<h2 class="hasAnchor" id="examples"><a class="anchor" href="#examples"></a>Examples</h2>
<pre class="examples"><div class='input'><span class='co'># Use shorthand notation for parent only degradation</span>
<span class='no'>fit</span> <span class='kw'><-</span> <span class='fu'>mkinfit</span>(<span class='st'>"FOMC"</span>, <span class='no'>FOCUS_2006_C</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)
<span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/summary'>summary</a></span>(<span class='no'>fit</span>)</div><div class='output co'>#> mkin version used for fitting: 0.9.49.4
#> R version used for fitting: 3.6.0
#> Date of fit: Tue May 7 08:36:16 2019
#> Date of summary: Tue May 7 08:36:16 2019
#>
#> Equations:
#> d_parent/dt = - (alpha/beta) * 1/((time/beta) + 1) * parent
#>
#> Model predictions using solution type analytical
#>
#> Fitted using 222 model solutions performed in 0.89 s
#>
#> Error model:
#> Constant variance
#>
#> Starting values for parameters to be optimised:
#> value type
#> parent_0 85.100000 state
#> alpha 1.000000 deparm
#> beta 10.000000 deparm
#> sigma 1.857444 error
#>
#> Starting values for the transformed parameters actually optimised:
#> value lower upper
#> parent_0 85.100000 -Inf Inf
#> log_alpha 0.000000 -Inf Inf
#> log_beta 2.302585 -Inf Inf
#> sigma 1.857444 0 Inf
#>
#> Fixed parameter values:
#> None
#>
#> Optimised, transformed parameters with symmetric confidence intervals:
#> Estimate Std. Error Lower Upper
#> parent_0 85.87000 1.8070 81.23000 90.5200
#> log_alpha 0.05192 0.1353 -0.29580 0.3996
#> log_beta 0.65100 0.2287 0.06315 1.2390
#> sigma 1.85700 0.4378 0.73200 2.9830
#>
#> Parameter correlation:
#> parent_0 log_alpha log_beta sigma
#> parent_0 1.000e+00 -1.565e-01 -3.142e-01 4.770e-08
#> log_alpha -1.565e-01 1.000e+00 9.564e-01 9.974e-08
#> log_beta -3.142e-01 9.564e-01 1.000e+00 8.468e-08
#> sigma 4.770e-08 9.974e-08 8.468e-08 1.000e+00
#>
#> Backtransformed parameters:
#> Confidence intervals for internally transformed parameters are asymmetric.
#> t-test (unrealistically) based on the assumption of normal distribution
#> for estimators of untransformed parameters.
#> Estimate t value Pr(>t) Lower Upper
#> parent_0 85.870 47.530 3.893e-08 81.2300 90.520
#> alpha 1.053 7.393 3.562e-04 0.7439 1.491
#> beta 1.917 4.373 3.601e-03 1.0650 3.451
#> sigma 1.857 4.243 4.074e-03 0.7320 2.983
#>
#> FOCUS Chi2 error levels in percent:
#> err.min n.optim df
#> All data 6.657 3 6
#> parent 6.657 3 6
#>
#> Estimated disappearance times:
#> DT50 DT90 DT50back
#> parent 1.785 15.15 4.56
#>
#> Data:
#> time variable observed predicted residual
#> 0 parent 85.1 85.875 -0.7749
#> 1 parent 57.9 55.191 2.7091
#> 3 parent 29.9 31.845 -1.9452
#> 7 parent 14.6 17.012 -2.4124
#> 14 parent 9.7 9.241 0.4590
#> 28 parent 6.6 4.754 1.8460
#> 63 parent 4.0 2.102 1.8977
#> 91 parent 3.9 1.441 2.4590
#> 119 parent 0.6 1.092 -0.4919</div><div class='input'>
<span class='co'># One parent compound, one metabolite, both single first order.</span>
<span class='co'># Use mkinsub for convenience in model formulation. Pathway to sink included per default.</span>
<span class='no'>SFO_SFO</span> <span class='kw'><-</span> <span class='fu'><a href='mkinmod.html'>mkinmod</a></span>(
<span class='kw'>parent</span> <span class='kw'>=</span> <span class='fu'><a href='mkinsub.html'>mkinsub</a></span>(<span class='st'>"SFO"</span>, <span class='st'>"m1"</span>),
<span class='kw'>m1</span> <span class='kw'>=</span> <span class='fu'><a href='mkinsub.html'>mkinsub</a></span>(<span class='st'>"SFO"</span>))</div><div class='output co'>#> <span class='message'>Successfully compiled differential equation model from auto-generated C code.</span></div><div class='input'><span class='co'># Fit the model to the FOCUS example dataset D using defaults</span>
<span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/print'>print</a></span>(<span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/system.time'>system.time</a></span>(<span class='no'>fit</span> <span class='kw'><-</span> <span class='fu'>mkinfit</span>(<span class='no'>SFO_SFO</span>, <span class='no'>FOCUS_2006_D</span>,
<span class='kw'>solution_type</span> <span class='kw'>=</span> <span class='st'>"eigen"</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)))</div><div class='output co'>#> <span class='warning'>Warning: Observations with value of zero were removed from the data</span></div><div class='output co'>#> User System verstrichen
#> 2.251 0.000 2.253 </div><div class='input'><span class='fu'><a href='https://www.rdocumentation.org/packages/stats/topics/coef'>coef</a></span>(<span class='no'>fit</span>)</div><div class='output co'>#> NULL</div><div class='input'><span class='fu'><a href='endpoints.html'>endpoints</a></span>(<span class='no'>fit</span>)</div><div class='output co'>#> $ff
#> parent_sink parent_m1 m1_sink
#> 0.485524 0.514476 1.000000
#>
#> $SFORB
#> logical(0)
#>
#> $distimes
#> DT50 DT90
#> parent 7.022929 23.32967
#> m1 131.760712 437.69961
#> </div><div class='input'><span class='co'># deSolve is slower when no C compiler (gcc) was available during model generation</span>
<span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/print'>print</a></span>(<span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/system.time'>system.time</a></span>(<span class='no'>fit.deSolve</span> <span class='kw'><-</span> <span class='fu'>mkinfit</span>(<span class='no'>SFO_SFO</span>, <span class='no'>FOCUS_2006_D</span>,
<span class='kw'>solution_type</span> <span class='kw'>=</span> <span class='st'>"deSolve"</span>)))</div><div class='output co'>#> <span class='warning'>Warning: Observations with value of zero were removed from the data</span></div><div class='output co'>#> <span class='message'>Ordinary least squares optimisation</span></div><div class='output co'>#> Sum of squared residuals at call 1: 18915.53
#> Sum of squared residuals at call 2: 18915.53
#> Sum of squared residuals at call 6: 11424.02
#> Sum of squared residuals at call 10: 11424
#> Sum of squared residuals at call 12: 4094.396
#> Sum of squared residuals at call 16: 4094.396
#> Sum of squared residuals at call 19: 1340.595
#> Sum of squared residuals at call 20: 1340.593
#> Sum of squared residuals at call 25: 1072.239
#> Sum of squared residuals at call 28: 1072.236
#> Sum of squared residuals at call 30: 874.2615
#> Sum of squared residuals at call 33: 874.2611
#> Sum of squared residuals at call 35: 616.2375
#> Sum of squared residuals at call 37: 616.237
#> Sum of squared residuals at call 40: 467.4386
#> Sum of squared residuals at call 42: 467.438
#> Sum of squared residuals at call 46: 398.2913
#> Sum of squared residuals at call 48: 398.2913
#> Sum of squared residuals at call 49: 398.2912
#> Sum of squared residuals at call 51: 395.0711
#> Sum of squared residuals at call 54: 395.071
#> Sum of squared residuals at call 56: 378.3298
#> Sum of squared residuals at call 59: 378.3298
#> Sum of squared residuals at call 62: 376.9812
#> Sum of squared residuals at call 64: 376.9811
#> Sum of squared residuals at call 67: 375.2085
#> Sum of squared residuals at call 69: 375.2085
#> Sum of squared residuals at call 70: 375.2085
#> Sum of squared residuals at call 71: 375.2085
#> Sum of squared residuals at call 72: 374.5723
#> Sum of squared residuals at call 74: 374.5723
#> Sum of squared residuals at call 77: 374.0075
#> Sum of squared residuals at call 79: 374.0075
#> Sum of squared residuals at call 80: 374.0075
#> Sum of squared residuals at call 82: 373.1711
#> Sum of squared residuals at call 84: 373.1711
#> Sum of squared residuals at call 87: 372.6445
#> Sum of squared residuals at call 88: 372.1615
#> Sum of squared residuals at call 90: 372.1615
#> Sum of squared residuals at call 91: 372.1615
#> Sum of squared residuals at call 94: 371.6464
#> Sum of squared residuals at call 99: 371.4299
#> Sum of squared residuals at call 101: 371.4299
#> Sum of squared residuals at call 104: 371.4071
#> Sum of squared residuals at call 106: 371.4071
#> Sum of squared residuals at call 107: 371.4071
#> Sum of squared residuals at call 109: 371.2524
#> Sum of squared residuals at call 113: 371.2524
#> Sum of squared residuals at call 114: 371.2136
#> Sum of squared residuals at call 115: 371.2136
#> Sum of squared residuals at call 116: 371.2136
#> Sum of squared residuals at call 119: 371.2134
#> Sum of squared residuals at call 120: 371.2134
#> Sum of squared residuals at call 122: 371.2134
#> Sum of squared residuals at call 123: 371.2134
#> Sum of squared residuals at call 125: 371.2134
#> Sum of squared residuals at call 126: 371.2134
#> Sum of squared residuals at call 135: 371.2134
#> Negative log-likelihood at call 145: 97.22429</div><div class='output co'>#> <span class='message'>Optimisation successfully terminated.</span></div><div class='output co'>#> User System verstrichen
#> 1.151 0.000 1.152 </div><div class='input'><span class='fu'><a href='https://www.rdocumentation.org/packages/stats/topics/coef'>coef</a></span>(<span class='no'>fit.deSolve</span>)</div><div class='output co'>#> NULL</div><div class='input'><span class='fu'><a href='endpoints.html'>endpoints</a></span>(<span class='no'>fit.deSolve</span>)</div><div class='output co'>#> $ff
#> parent_sink parent_m1 m1_sink
#> 0.485524 0.514476 1.000000
#>
#> $SFORB
#> logical(0)
#>
#> $distimes
#> DT50 DT90
#> parent 7.022929 23.32967
#> m1 131.760712 437.69961
#> </div><div class='input'>
# Use stepwise fitting, using optimised parameters from parent only fit, FOMC
</div><div class='input'><span class='no'>FOMC_SFO</span> <span class='kw'><-</span> <span class='fu'><a href='mkinmod.html'>mkinmod</a></span>(
<span class='kw'>parent</span> <span class='kw'>=</span> <span class='fu'><a href='mkinsub.html'>mkinsub</a></span>(<span class='st'>"FOMC"</span>, <span class='st'>"m1"</span>),
<span class='kw'>m1</span> <span class='kw'>=</span> <span class='fu'><a href='mkinsub.html'>mkinsub</a></span>(<span class='st'>"SFO"</span>))</div><div class='output co'>#> <span class='message'>Successfully compiled differential equation model from auto-generated C code.</span></div><div class='input'><span class='co'># Fit the model to the FOCUS example dataset D using defaults</span>
<span class='no'>fit.FOMC_SFO</span> <span class='kw'><-</span> <span class='fu'>mkinfit</span>(<span class='no'>FOMC_SFO</span>, <span class='no'>FOCUS_2006_D</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)</div><div class='output co'>#> <span class='warning'>Warning: Observations with value of zero were removed from the data</span></div><div class='input'><span class='co'># Use starting parameters from parent only FOMC fit</span>
<span class='no'>fit.FOMC</span> <span class='kw'>=</span> <span class='fu'>mkinfit</span>(<span class='st'>"FOMC"</span>, <span class='no'>FOCUS_2006_D</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)
<span class='no'>fit.FOMC_SFO</span> <span class='kw'><-</span> <span class='fu'>mkinfit</span>(<span class='no'>FOMC_SFO</span>, <span class='no'>FOCUS_2006_D</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>,
<span class='kw'>parms.ini</span> <span class='kw'>=</span> <span class='no'>fit.FOMC</span>$<span class='no'>bparms.ode</span>)</div><div class='output co'>#> <span class='warning'>Warning: Observations with value of zero were removed from the data</span></div><div class='input'>
<span class='co'># Use stepwise fitting, using optimised parameters from parent only fit, SFORB</span>
<span class='no'>SFORB_SFO</span> <span class='kw'><-</span> <span class='fu'><a href='mkinmod.html'>mkinmod</a></span>(
<span class='kw'>parent</span> <span class='kw'>=</span> <span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/list'>list</a></span>(<span class='kw'>type</span> <span class='kw'>=</span> <span class='st'>"SFORB"</span>, <span class='kw'>to</span> <span class='kw'>=</span> <span class='st'>"m1"</span>, <span class='kw'>sink</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>),
<span class='kw'>m1</span> <span class='kw'>=</span> <span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/list'>list</a></span>(<span class='kw'>type</span> <span class='kw'>=</span> <span class='st'>"SFO"</span>))</div><div class='output co'>#> <span class='message'>Successfully compiled differential equation model from auto-generated C code.</span></div><div class='input'><span class='co'># Fit the model to the FOCUS example dataset D using defaults</span>
<span class='no'>fit.SFORB_SFO</span> <span class='kw'><-</span> <span class='fu'>mkinfit</span>(<span class='no'>SFORB_SFO</span>, <span class='no'>FOCUS_2006_D</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)</div><div class='output co'>#> <span class='warning'>Warning: Observations with value of zero were removed from the data</span></div><div class='input'><span class='no'>fit.SFORB_SFO.deSolve</span> <span class='kw'><-</span> <span class='fu'>mkinfit</span>(<span class='no'>SFORB_SFO</span>, <span class='no'>FOCUS_2006_D</span>, <span class='kw'>solution_type</span> <span class='kw'>=</span> <span class='st'>"deSolve"</span>,
<span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)</div><div class='output co'>#> <span class='warning'>Warning: Observations with value of zero were removed from the data</span></div><div class='input'><span class='co'># Use starting parameters from parent only SFORB fit (not really needed in this case)</span>
<span class='no'>fit.SFORB</span> <span class='kw'>=</span> <span class='fu'>mkinfit</span>(<span class='st'>"SFORB"</span>, <span class='no'>FOCUS_2006_D</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)
<span class='no'>fit.SFORB_SFO</span> <span class='kw'><-</span> <span class='fu'>mkinfit</span>(<span class='no'>SFORB_SFO</span>, <span class='no'>FOCUS_2006_D</span>, <span class='kw'>parms.ini</span> <span class='kw'>=</span> <span class='no'>fit.SFORB</span>$<span class='no'>bparms.ode</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)</div><div class='output co'>#> <span class='warning'>Warning: Observations with value of zero were removed from the data</span></div><div class='input'>
</div><div class='input'><span class='co'># Weighted fits, including IRLS</span>
<span class='no'>SFO_SFO.ff</span> <span class='kw'><-</span> <span class='fu'><a href='mkinmod.html'>mkinmod</a></span>(<span class='kw'>parent</span> <span class='kw'>=</span> <span class='fu'><a href='mkinsub.html'>mkinsub</a></span>(<span class='st'>"SFO"</span>, <span class='st'>"m1"</span>),
<span class='kw'>m1</span> <span class='kw'>=</span> <span class='fu'><a href='mkinsub.html'>mkinsub</a></span>(<span class='st'>"SFO"</span>), <span class='kw'>use_of_ff</span> <span class='kw'>=</span> <span class='st'>"max"</span>)</div><div class='output co'>#> <span class='message'>Successfully compiled differential equation model from auto-generated C code.</span></div><div class='input'><span class='no'>f.noweight</span> <span class='kw'><-</span> <span class='fu'>mkinfit</span>(<span class='no'>SFO_SFO.ff</span>, <span class='no'>FOCUS_2006_D</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)</div><div class='output co'>#> <span class='warning'>Warning: Observations with value of zero were removed from the data</span></div><div class='input'><span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/summary'>summary</a></span>(<span class='no'>f.noweight</span>)</div><div class='output co'>#> mkin version used for fitting: 0.9.49.4
#> R version used for fitting: 3.6.0
#> Date of fit: Tue May 7 08:36:33 2019
#> Date of summary: Tue May 7 08:36:33 2019
#>
#> Equations:
#> d_parent/dt = - k_parent * parent
#> d_m1/dt = + f_parent_to_m1 * k_parent * parent - k_m1 * m1
#>
#> Model predictions using solution type deSolve
#>
#> Fitted using 421 model solutions performed in 1.1 s
#>
#> Error model:
#> Constant variance
#>
#> Starting values for parameters to be optimised:
#> value type
#> parent_0 100.750000 state
#> k_parent 0.100000 deparm
#> k_m1 0.100100 deparm
#> f_parent_to_m1 0.500000 deparm
#> sigma 3.125504 error
#>
#> Starting values for the transformed parameters actually optimised:
#> value lower upper
#> parent_0 100.750000 -Inf Inf
#> log_k_parent -2.302585 -Inf Inf
#> log_k_m1 -2.301586 -Inf Inf
#> f_parent_ilr_1 0.000000 -Inf Inf
#> sigma 3.125504 0 Inf
#>
#> Fixed parameter values:
#> value type
#> m1_0 0 state
#>
#> Optimised, transformed parameters with symmetric confidence intervals:
#> Estimate Std. Error Lower Upper
#> parent_0 99.60000 1.57000 96.40000 102.8000
#> log_k_parent -2.31600 0.04087 -2.39900 -2.2330
#> log_k_m1 -5.24800 0.13320 -5.51800 -4.9770
#> f_parent_ilr_1 0.04096 0.06312 -0.08746 0.1694
#> sigma 3.12600 0.35850 2.39600 3.8550
#>
#> Parameter correlation:
#> parent_0 log_k_parent log_k_m1 f_parent_ilr_1 sigma
#> parent_0 1.000e+00 5.174e-01 -1.688e-01 -5.471e-01 -2.265e-07
#> log_k_parent 5.174e-01 1.000e+00 -3.263e-01 -5.426e-01 3.785e-07
#> log_k_m1 -1.688e-01 -3.263e-01 1.000e+00 7.478e-01 -1.386e-07
#> f_parent_ilr_1 -5.471e-01 -5.426e-01 7.478e-01 1.000e+00 -3.641e-08
#> sigma -2.265e-07 3.785e-07 -1.386e-07 -3.641e-08 1.000e+00
#>
#> Backtransformed parameters:
#> Confidence intervals for internally transformed parameters are asymmetric.
#> t-test (unrealistically) based on the assumption of normal distribution
#> for estimators of untransformed parameters.
#> Estimate t value Pr(>t) Lower Upper
#> parent_0 99.600000 63.430 2.298e-36 96.400000 1.028e+02
#> k_parent 0.098700 24.470 4.955e-23 0.090820 1.073e-01
#> k_m1 0.005261 7.510 6.165e-09 0.004012 6.898e-03
#> f_parent_to_m1 0.514500 23.070 3.104e-22 0.469100 5.596e-01
#> sigma 3.126000 8.718 2.235e-10 2.396000 3.855e+00
#>
#> FOCUS Chi2 error levels in percent:
#> err.min n.optim df
#> All data 6.398 4 15
#> parent 6.459 2 7
#> m1 4.690 2 8
#>
#> Resulting formation fractions:
#> ff
#> parent_m1 0.5145
#> parent_sink 0.4855
#>
#> Estimated disappearance times:
#> DT50 DT90
#> parent 7.023 23.33
#> m1 131.761 437.70
#>
#> Data:
#> time variable observed predicted residual
#> 0 parent 99.46 99.59848 -1.385e-01
#> 0 parent 102.04 99.59848 2.442e+00
#> 1 parent 93.50 90.23787 3.262e+00
#> 1 parent 92.50 90.23787 2.262e+00
#> 3 parent 63.23 74.07319 -1.084e+01
#> 3 parent 68.99 74.07319 -5.083e+00
#> 7 parent 52.32 49.91206 2.408e+00
#> 7 parent 55.13 49.91206 5.218e+00
#> 14 parent 27.27 25.01257 2.257e+00
#> 14 parent 26.64 25.01257 1.627e+00
#> 21 parent 11.50 12.53462 -1.035e+00
#> 21 parent 11.64 12.53462 -8.946e-01
#> 35 parent 2.85 3.14787 -2.979e-01
#> 35 parent 2.91 3.14787 -2.379e-01
#> 50 parent 0.69 0.71624 -2.624e-02
#> 50 parent 0.63 0.71624 -8.624e-02
#> 75 parent 0.05 0.06074 -1.074e-02
#> 75 parent 0.06 0.06074 -7.381e-04
#> 1 m1 4.84 4.80296 3.704e-02
#> 1 m1 5.64 4.80296 8.370e-01
#> 3 m1 12.91 13.02400 -1.140e-01
#> 3 m1 12.96 13.02400 -6.400e-02
#> 7 m1 22.97 25.04476 -2.075e+00
#> 7 m1 24.47 25.04476 -5.748e-01
#> 14 m1 41.69 36.69002 5.000e+00
#> 14 m1 33.21 36.69002 -3.480e+00
#> 21 m1 44.37 41.65310 2.717e+00
#> 21 m1 46.44 41.65310 4.787e+00
#> 35 m1 41.22 43.31312 -2.093e+00
#> 35 m1 37.95 43.31312 -5.363e+00
#> 50 m1 41.19 41.21831 -2.831e-02
#> 50 m1 40.01 41.21831 -1.208e+00
#> 75 m1 40.09 36.44703 3.643e+00
#> 75 m1 33.85 36.44703 -2.597e+00
#> 100 m1 31.04 31.98163 -9.416e-01
#> 100 m1 33.13 31.98163 1.148e+00
#> 120 m1 25.15 28.78984 -3.640e+00
#> 120 m1 33.31 28.78984 4.520e+00</div><div class='input'><span class='no'>f.obs</span> <span class='kw'><-</span> <span class='fu'>mkinfit</span>(<span class='no'>SFO_SFO.ff</span>, <span class='no'>FOCUS_2006_D</span>, <span class='kw'>error_model</span> <span class='kw'>=</span> <span class='st'>"obs"</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)</div><div class='output co'>#> <span class='warning'>Warning: Observations with value of zero were removed from the data</span></div><div class='input'><span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/summary'>summary</a></span>(<span class='no'>f.obs</span>)</div><div class='output co'>#> mkin version used for fitting: 0.9.49.4
#> R version used for fitting: 3.6.0
#> Date of fit: Tue May 7 08:36:35 2019
#> Date of summary: Tue May 7 08:36:35 2019
#>
#> Equations:
#> d_parent/dt = - k_parent * parent
#> d_m1/dt = + f_parent_to_m1 * k_parent * parent - k_m1 * m1
#>
#> Model predictions using solution type deSolve
#>
#> Fitted using 758 model solutions performed in 1.991 s
#>
#> Error model:
#> Variance unique to each observed variable
#>
#> Starting values for parameters to be optimised:
#> value type
#> parent_0 100.7500 state
#> k_parent 0.1000 deparm
#> k_m1 0.1001 deparm
#> f_parent_to_m1 0.5000 deparm
#> sigma_parent 3.0000 error
#> sigma_m1 3.0000 error
#>
#> Starting values for the transformed parameters actually optimised:
#> value lower upper
#> parent_0 100.750000 -Inf Inf
#> log_k_parent -2.302585 -Inf Inf
#> log_k_m1 -2.301586 -Inf Inf
#> f_parent_ilr_1 0.000000 -Inf Inf
#> sigma_parent 3.000000 0 Inf
#> sigma_m1 3.000000 0 Inf
#>
#> Fixed parameter values:
#> value type
#> m1_0 0 state
#>
#> Optimised, transformed parameters with symmetric confidence intervals:
#> Estimate Std. Error Lower Upper
#> parent_0 99.65000 1.70200 96.19000 103.1000
#> log_k_parent -2.31300 0.04376 -2.40200 -2.2240
#> log_k_m1 -5.25000 0.12430 -5.50400 -4.9970
#> f_parent_ilr_1 0.03861 0.06171 -0.08708 0.1643
#> sigma_parent 3.40100 0.56820 2.24400 4.5590
#> sigma_m1 2.85500 0.45240 1.93400 3.7770
#>
#> Parameter correlation:
#> parent_0 log_k_parent log_k_m1 f_parent_ilr_1 sigma_parent
#> parent_0 1.00000 0.51078 -0.19133 -0.59997 0.035670
#> log_k_parent 0.51078 1.00000 -0.37458 -0.59239 0.069833
#> log_k_m1 -0.19133 -0.37458 1.00000 0.74398 -0.026158
#> f_parent_ilr_1 -0.59997 -0.59239 0.74398 1.00000 -0.041368
#> sigma_parent 0.03567 0.06983 -0.02616 -0.04137 1.000000
#> sigma_m1 -0.03385 -0.06627 0.02482 0.03925 -0.004628
#> sigma_m1
#> parent_0 -0.033847
#> log_k_parent -0.066265
#> log_k_m1 0.024821
#> f_parent_ilr_1 0.039255
#> sigma_parent -0.004628
#> sigma_m1 1.000000
#>
#> Backtransformed parameters:
#> Confidence intervals for internally transformed parameters are asymmetric.
#> t-test (unrealistically) based on the assumption of normal distribution
#> for estimators of untransformed parameters.
#> Estimate t value Pr(>t) Lower Upper
#> parent_0 99.650000 58.560 2.004e-34 96.190000 1.031e+02
#> k_parent 0.098970 22.850 1.099e-21 0.090530 1.082e-01
#> k_m1 0.005245 8.046 1.732e-09 0.004072 6.756e-03
#> f_parent_to_m1 0.513600 23.560 4.352e-22 0.469300 5.578e-01
#> sigma_parent 3.401000 5.985 5.662e-07 2.244000 4.559e+00
#> sigma_m1 2.855000 6.311 2.215e-07 1.934000 3.777e+00
#>
#> FOCUS Chi2 error levels in percent:
#> err.min n.optim df
#> All data 6.398 4 15
#> parent 6.464 2 7
#> m1 4.682 2 8
#>
#> Resulting formation fractions:
#> ff
#> parent_m1 0.5136
#> parent_sink 0.4864
#>
#> Estimated disappearance times:
#> DT50 DT90
#> parent 7.003 23.26
#> m1 132.154 439.01
#>
#> Data:
#> time variable observed predicted residual
#> 0 parent 99.46 99.65417 -1.942e-01
#> 0 parent 102.04 99.65417 2.386e+00
#> 1 parent 93.50 90.26332 3.237e+00
#> 1 parent 92.50 90.26332 2.237e+00
#> 3 parent 63.23 74.05306 -1.082e+01
#> 3 parent 68.99 74.05306 -5.063e+00
#> 7 parent 52.32 49.84325 2.477e+00
#> 7 parent 55.13 49.84325 5.287e+00
#> 14 parent 27.27 24.92971 2.340e+00
#> 14 parent 26.64 24.92971 1.710e+00
#> 21 parent 11.50 12.46890 -9.689e-01
#> 21 parent 11.64 12.46890 -8.289e-01
#> 35 parent 2.85 3.11925 -2.692e-01
#> 35 parent 2.91 3.11925 -2.092e-01
#> 50 parent 0.69 0.70679 -1.679e-02
#> 50 parent 0.63 0.70679 -7.679e-02
#> 75 parent 0.05 0.05952 -9.523e-03
#> 75 parent 0.06 0.05952 4.772e-04
#> 1 m1 4.84 4.81075 2.925e-02
#> 1 m1 5.64 4.81075 8.292e-01
#> 3 m1 12.91 13.04196 -1.320e-01
#> 3 m1 12.96 13.04196 -8.196e-02
#> 7 m1 22.97 25.06847 -2.098e+00
#> 7 m1 24.47 25.06847 -5.985e-01
#> 14 m1 41.69 36.70308 4.987e+00
#> 14 m1 33.21 36.70308 -3.493e+00
#> 21 m1 44.37 41.65115 2.719e+00
#> 21 m1 46.44 41.65115 4.789e+00
#> 35 m1 41.22 43.29465 -2.075e+00
#> 35 m1 37.95 43.29465 -5.345e+00
#> 50 m1 41.19 41.19948 -9.481e-03
#> 50 m1 40.01 41.19948 -1.189e+00
#> 75 m1 40.09 36.44036 3.650e+00
#> 75 m1 33.85 36.44036 -2.590e+00
#> 100 m1 31.04 31.98774 -9.477e-01
#> 100 m1 33.13 31.98774 1.142e+00
#> 120 m1 25.15 28.80430 -3.654e+00
#> 120 m1 33.31 28.80430 4.506e+00</div><div class='input'><span class='no'>f.tc</span> <span class='kw'><-</span> <span class='fu'>mkinfit</span>(<span class='no'>SFO_SFO.ff</span>, <span class='no'>FOCUS_2006_D</span>, <span class='kw'>error_model</span> <span class='kw'>=</span> <span class='st'>"tc"</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)</div><div class='output co'>#> <span class='warning'>Warning: Observations with value of zero were removed from the data</span></div><div class='input'><span class='fu'><a href='https://www.rdocumentation.org/packages/base/topics/summary'>summary</a></span>(<span class='no'>f.tc</span>)</div><div class='output co'>#> mkin version used for fitting: 0.9.49.4
#> R version used for fitting: 3.6.0
#> Date of fit: Tue May 7 08:36:39 2019
#> Date of summary: Tue May 7 08:36:39 2019
#>
#> Equations:
#> d_parent/dt = - k_parent * parent
#> d_m1/dt = + f_parent_to_m1 * k_parent * parent - k_m1 * m1
#>
#> Model predictions using solution type deSolve
#>
#> Fitted using 821 model solutions performed in 3.304 s
#>
#> Error model:
#> Two-component variance function
#>
#> Starting values for parameters to be optimised:
#> value type
#> parent_0 100.7500 state
#> k_parent 0.1000 deparm
#> k_m1 0.1001 deparm
#> f_parent_to_m1 0.5000 deparm
#> sigma_low 0.1000 error
#> rsd_high 0.1000 error
#>
#> Starting values for the transformed parameters actually optimised:
#> value lower upper
#> parent_0 100.750000 -Inf Inf
#> log_k_parent -2.302585 -Inf Inf
#> log_k_m1 -2.301586 -Inf Inf
#> f_parent_ilr_1 0.000000 -Inf Inf
#> sigma_low 0.100000 0 Inf
#> rsd_high 0.100000 0 Inf
#>
#> Fixed parameter values:
#> value type
#> m1_0 0 state
#>
#> Optimised, transformed parameters with symmetric confidence intervals:
#> Estimate Std. Error Lower Upper
#> parent_0 100.70000 2.621000 95.400000 106.10000
#> log_k_parent -2.29700 0.008862 -2.315000 -2.27900
#> log_k_m1 -5.26600 0.091310 -5.452000 -5.08000
#> f_parent_ilr_1 0.02374 0.055300 -0.088900 0.13640
#> sigma_low 0.00305 0.004829 -0.006786 0.01289
#> rsd_high 0.07928 0.009418 0.060100 0.09847
#>
#> Parameter correlation:
#> parent_0 log_k_parent log_k_m1 f_parent_ilr_1 sigma_low rsd_high
#> parent_0 1.00000 0.67644 -0.10215 -0.76822 0.14294 -0.08783
#> log_k_parent 0.67644 1.00000 -0.15102 -0.59491 0.34611 -0.08125
#> log_k_m1 -0.10215 -0.15102 1.00000 0.51808 -0.05236 0.01240
#> f_parent_ilr_1 -0.76822 -0.59491 0.51808 1.00000 -0.13900 0.03248
#> sigma_low 0.14294 0.34611 -0.05236 -0.13900 1.00000 -0.16546
#> rsd_high -0.08783 -0.08125 0.01240 0.03248 -0.16546 1.00000
#>
#> Backtransformed parameters:
#> Confidence intervals for internally transformed parameters are asymmetric.
#> t-test (unrealistically) based on the assumption of normal distribution
#> for estimators of untransformed parameters.
#> Estimate t value Pr(>t) Lower Upper
#> parent_0 1.007e+02 38.4300 1.180e-28 95.400000 1.061e+02
#> k_parent 1.006e-01 112.8000 1.718e-43 0.098760 1.024e-01
#> k_m1 5.167e-03 10.9500 1.172e-12 0.004290 6.223e-03
#> f_parent_to_m1 5.084e-01 26.0100 2.146e-23 0.468600 5.481e-01
#> sigma_low 3.050e-03 0.6314 2.661e-01 -0.006786 1.289e-02
#> rsd_high 7.928e-02 8.4170 6.418e-10 0.060100 9.847e-02
#>
#> FOCUS Chi2 error levels in percent:
#> err.min n.optim df
#> All data 6.475 4 15
#> parent 6.573 2 7
#> m1 4.671 2 8
#>
#> Resulting formation fractions:
#> ff
#> parent_m1 0.5084
#> parent_sink 0.4916
#>
#> Estimated disappearance times:
#> DT50 DT90
#> parent 6.893 22.9
#> m1 134.156 445.7
#>
#> Data:
#> time variable observed predicted residual
#> 0 parent 99.46 100.73433 -1.274329
#> 0 parent 102.04 100.73433 1.305671
#> 1 parent 93.50 91.09750 2.402495
#> 1 parent 92.50 91.09750 1.402495
#> 3 parent 63.23 74.50140 -11.271403
#> 3 parent 68.99 74.50140 -5.511403
#> 7 parent 52.32 49.82880 2.491205
#> 7 parent 55.13 49.82880 5.301205
#> 14 parent 27.27 24.64809 2.621909
#> 14 parent 26.64 24.64809 1.991909
#> 21 parent 11.50 12.19231 -0.692315
#> 21 parent 11.64 12.19231 -0.552315
#> 35 parent 2.85 2.98327 -0.133266
#> 35 parent 2.91 2.98327 -0.073266
#> 50 parent 0.69 0.66013 0.029874
#> 50 parent 0.63 0.66013 -0.030126
#> 75 parent 0.05 0.05344 -0.003438
#> 75 parent 0.06 0.05344 0.006562
#> 1 m1 4.84 4.88645 -0.046451
#> 1 m1 5.64 4.88645 0.753549
#> 3 m1 12.91 13.22867 -0.318668
#> 3 m1 12.96 13.22867 -0.268668
#> 7 m1 22.97 25.36416 -2.394164
#> 7 m1 24.47 25.36416 -0.894164
#> 14 m1 41.69 37.00974 4.680265
#> 14 m1 33.21 37.00974 -3.799735
#> 21 m1 44.37 41.90133 2.468670
#> 21 m1 46.44 41.90133 4.538670
#> 35 m1 41.22 43.45691 -2.236914
#> 35 m1 37.95 43.45691 -5.506914
#> 50 m1 41.19 41.34199 -0.151988
#> 50 m1 40.01 41.34199 -1.331988
#> 75 m1 40.09 36.61471 3.475290
#> 75 m1 33.85 36.61471 -2.764710
#> 100 m1 31.04 32.20083 -1.160830
#> 100 m1 33.13 32.20083 0.929170
#> 120 m1 25.15 29.04131 -3.891312
#> 120 m1 33.31 29.04131 4.268688</div><div class='input'>
</div></pre>
</div>
<div class="col-md-3 hidden-xs hidden-sm" id="sidebar">
<h2>Contents</h2>
<ul class="nav nav-pills nav-stacked">
<li><a href="#arguments">Arguments</a></li>
<li><a href="#value">Value</a></li>
<li><a href="#see-also">See also</a></li>
<li><a href="#note">Note</a></li>
<li><a href="#source">Source</a></li>
<li><a href="#examples">Examples</a></li>
</ul>
<h2>Author</h2>
<p>Johannes Ranke</p>
</div>
</div>
<footer>
<div class="copyright">
<p>Developed by Johannes Ranke.</p>
</div>
<div class="pkgdown">
<p>Site built with <a href="https://pkgdown.r-lib.org/">pkgdown</a> 1.3.0.9000.</p>
</div>
</footer>
</div>
</body>
</html>
|