diff options
Diffstat (limited to 'inst/web')
-rw-r--r-- | inst/web/Extract.mmkin.html | 24 | ||||
-rw-r--r-- | inst/web/mccall81_245T.html | 6 | ||||
-rw-r--r-- | inst/web/mkinfit.html | 8 | ||||
-rw-r--r-- | inst/web/mkinmod.html | 61 | ||||
-rw-r--r-- | inst/web/mkinpredict.html | 6 | ||||
-rw-r--r-- | inst/web/summary.mkinfit.html | 6 | ||||
-rw-r--r-- | inst/web/transform_odeparms.html | 6 | ||||
-rw-r--r-- | inst/web/vignettes/FOCUS_Z.pdf | bin | 224802 -> 224775 bytes | |||
-rw-r--r-- | inst/web/vignettes/compiled_models.html | 34 | ||||
-rw-r--r-- | inst/web/vignettes/mkin.pdf | bin | 160268 -> 160268 bytes |
10 files changed, 62 insertions, 89 deletions
diff --git a/inst/web/Extract.mmkin.html b/inst/web/Extract.mmkin.html index c6ae3ef7..6a175a02 100644 --- a/inst/web/Extract.mmkin.html +++ b/inst/web/Extract.mmkin.html @@ -181,7 +181,7 @@ $calls $time user system elapsed - 0.260 0.000 0.262 + 0.268 0.000 0.269 $mkinmod <mkinmod> model generated with @@ -367,7 +367,7 @@ function (P) } return(mC) } -<environment: 0x2a98780> +<environment: 0x2d96b00> $cost_notrans function (P) @@ -389,7 +389,7 @@ function (P) scaleVar = scaleVar) return(mC) } -<environment: 0x2a98780> +<environment: 0x2d96b00> $hessian_notrans parent_0 alpha beta @@ -455,7 +455,7 @@ $bparms.state 99.66619 $date -[1] "Mon Nov 9 09:05:53 2015" +[1] "Mon Nov 9 10:11:49 2015" attr(,"class") [1] "mkinfit" "modFit" @@ -540,7 +540,7 @@ $calls $time user system elapsed - 0.088 0.000 0.086 + 0.112 0.000 0.112 $mkinmod <mkinmod> model generated with @@ -727,7 +727,7 @@ function (P) } return(mC) } -<environment: 0x2ca6db8> +<environment: 0x2fa3d28> $cost_notrans function (P) @@ -749,7 +749,7 @@ function (P) scaleVar = scaleVar) return(mC) } -<environment: 0x2ca6db8> +<environment: 0x2fa3d28> $hessian_notrans parent_0 k_parent_sink @@ -812,7 +812,7 @@ $bparms.state 99.17407 $date -[1] "Mon Nov 9 09:05:53 2015" +[1] "Mon Nov 9 10:11:48 2015" attr(,"class") [1] "mkinfit" "modFit" @@ -890,7 +890,7 @@ $calls $time user system elapsed - 0.088 0.000 0.086 + 0.112 0.000 0.112 $mkinmod <mkinmod> model generated with @@ -1077,7 +1077,7 @@ function (P) } return(mC) } -<environment: 0x2ca6db8> +<environment: 0x2fa3d28> $cost_notrans function (P) @@ -1099,7 +1099,7 @@ function (P) scaleVar = scaleVar) return(mC) } -<environment: 0x2ca6db8> +<environment: 0x2fa3d28> $hessian_notrans parent_0 k_parent_sink @@ -1162,7 +1162,7 @@ $bparms.state 99.17407 $date -[1] "Mon Nov 9 09:05:53 2015" +[1] "Mon Nov 9 10:11:48 2015" attr(,"class") [1] "mkinfit" "modFit" diff --git a/inst/web/mccall81_245T.html b/inst/web/mccall81_245T.html index f7a454ca..cd8d4d73 100644 --- a/inst/web/mccall81_245T.html +++ b/inst/web/mccall81_245T.html @@ -114,8 +114,8 @@ </div> <div class='output'>mkin version: 0.9.41 R version: 3.2.2 -Date of fit: Mon Nov 9 09:06:00 2015 -Date of summary: Mon Nov 9 09:06:00 2015 +Date of fit: Mon Nov 9 10:11:56 2015 +Date of summary: Mon Nov 9 10:11:56 2015 Equations: d_T245 = - k_T245_sink * T245 - k_T245_phenol * T245 @@ -124,7 +124,7 @@ d_anisole = + k_phenol_anisole * phenol - k_anisole_sink * anisole Model predictions using solution type deSolve -Fitted with method Port using 246 model solutions performed in 1.372 s +Fitted with method Port using 246 model solutions performed in 1.39 s Weighting: none diff --git a/inst/web/mkinfit.html b/inst/web/mkinfit.html index 96bdf95f..0550ee65 100644 --- a/inst/web/mkinfit.html +++ b/inst/web/mkinfit.html @@ -317,15 +317,15 @@ summary(fit) </div> <div class='output'>mkin version: 0.9.41 R version: 3.2.2 -Date of fit: Mon Nov 9 09:06:03 2015 -Date of summary: Mon Nov 9 09:06:03 2015 +Date of fit: Mon Nov 9 10:11:58 2015 +Date of summary: Mon Nov 9 10:11:58 2015 Equations: d_parent = - (alpha/beta) * 1/((time/beta) + 1) * parent Model predictions using solution type analytical -Fitted with method Port using 64 model solutions performed in 0.18 s +Fitted with method Port using 64 model solutions performed in 0.194 s Weighting: none @@ -401,7 +401,7 @@ print(system.time(fit <- mkinfit(SFO_SFO, FOCUS_2006_D, solution_type = "eigen", quiet = TRUE))) </div> <div class='output'> user system elapsed - 1.180 1.196 0.889 + 1.188 1.228 0.910 </div> <div class='input'>coef(fit) </div> diff --git a/inst/web/mkinmod.html b/inst/web/mkinmod.html index 797e96d5..7b43beb7 100644 --- a/inst/web/mkinmod.html +++ b/inst/web/mkinmod.html @@ -170,51 +170,24 @@ SFO_SFO <- mkinmod( </div> <strong class='message'>Successfully compiled differential equation model from auto-generated C code.</strong> <div class='input'> -# The above model used to be specified like this, before the advent of mkinsub() -SFO_SFO <- mkinmod( - parent = list(type = "SFO", to = "m1"), - m1 = list(type = "SFO")) -</div> -<strong class='message'>Successfully compiled differential equation model from auto-generated C code.</strong> -<div class='input'> -# Show details of creating the C function -SFO_SFO <- mkinmod( - parent = mkinsub("SFO", "m1"), - m1 = mkinsub("SFO"), verbose = TRUE) -</div> -<div class='output'>Compilation argument: - /usr/lib/R/bin/R CMD SHLIB file16d352645eb9.c 2> file16d352645eb9.c.err.txt -Program source: - 1: #include <R.h> - 2: - 3: - 4: static double parms [3]; - 5: #define k_parent_sink parms[0] - 6: #define k_parent_m1 parms[1] - 7: #define k_m1_sink parms[2] - 8: - 9: void initpar(void (* odeparms)(int *, double *)) { - 10: int N = 3; - 11: odeparms(&N, parms); - 12: } - 13: - 14: - 15: void func ( int * n, double * t, double * y, double * f, double * rpar, int * ipar ) { - 16: - 17: f[0] = - k_parent_sink * y[0] - k_parent_m1 * y[0]; - 18: f[1] = + k_parent_m1 * y[0] - k_m1_sink * y[1]; - 19: } -</div> -<strong class='message'>Successfully compiled differential equation model from auto-generated C code.</strong> -<div class='input'> -# If we have several parallel metabolites -# (compare tests/testthat/test_synthetic_data_for_UBA_2014.R) -m_synth_DFOP_par <- mkinmod(parent = mkinsub("DFOP", c("M1", "M2")), - M1 = mkinsub("SFO"), - M2 = mkinsub("SFO"), - use_of_ff = "max", quiet = TRUE) - ## Not run: +# # The above model used to be specified like this, before the advent of mkinsub() +# SFO_SFO <- mkinmod( +# parent = list(type = "SFO", to = "m1"), +# m1 = list(type = "SFO")) +# +# # Show details of creating the C function +# SFO_SFO <- mkinmod( +# parent = mkinsub("SFO", "m1"), +# m1 = mkinsub("SFO"), verbose = TRUE) +# +# # If we have several parallel metabolites +# # (compare tests/testthat/test_synthetic_data_for_UBA_2014.R) +# m_synth_DFOP_par <- mkinmod(parent = mkinsub("DFOP", c("M1", "M2")), +# M1 = mkinsub("SFO"), +# M2 = mkinsub("SFO"), +# use_of_ff = "max", quiet = TRUE) +# # fit_DFOP_par_c <- mkinfit(m_synth_DFOP_par, # synthetic_data_for_UBA_2014[[12]]$data, # quiet = TRUE) diff --git a/inst/web/mkinpredict.html b/inst/web/mkinpredict.html index 3a6300d0..900ee26f 100644 --- a/inst/web/mkinpredict.html +++ b/inst/web/mkinpredict.html @@ -304,7 +304,7 @@ 201 20 4.978707 27.46227 </div> <div class='output'> user system elapsed - 0.008 0.024 0.004 + 0.004 0.028 0.005 </div> <div class='input'> system.time( print(mkinpredict(SFO_SFO, c(k_parent_m1 = 0.05, k_parent_sink = 0.1, k_m1_sink = 0.01), @@ -315,7 +315,7 @@ 201 20 4.978707 27.46227 </div> <div class='output'> user system elapsed - 0.004 0.020 0.002 + 0.020 0.000 0.003 </div> <div class='input'> system.time( print(mkinpredict(SFO_SFO, c(k_parent_m1 = 0.05, k_parent_sink = 0.1, k_m1_sink = 0.01), @@ -326,7 +326,7 @@ 201 20 4.978707 27.46227 </div> <div class='output'> user system elapsed - 0.064 0.000 0.066 + 0.092 0.000 0.092 </div></pre> </div> <div class="span4"> diff --git a/inst/web/summary.mkinfit.html b/inst/web/summary.mkinfit.html index 02469bb6..2958b020 100644 --- a/inst/web/summary.mkinfit.html +++ b/inst/web/summary.mkinfit.html @@ -159,15 +159,15 @@ </div> <div class='output'>mkin version: 0.9.41 R version: 3.2.2 -Date of fit: Mon Nov 9 09:06:13 2015 -Date of summary: Mon Nov 9 09:06:13 2015 +Date of fit: Mon Nov 9 10:12:08 2015 +Date of summary: Mon Nov 9 10:12:08 2015 Equations: d_parent = - k_parent_sink * parent Model predictions using solution type analytical -Fitted with method Port using 35 model solutions performed in 0.1 s +Fitted with method Port using 35 model solutions performed in 0.105 s Weighting: none diff --git a/inst/web/transform_odeparms.html b/inst/web/transform_odeparms.html index 25dcaba9..36dfecf8 100644 --- a/inst/web/transform_odeparms.html +++ b/inst/web/transform_odeparms.html @@ -135,8 +135,8 @@ summary(fit, data=FALSE) # See transformed and backtransformed parameters </div> <div class='output'>mkin version: 0.9.41 R version: 3.2.2 -Date of fit: Mon Nov 9 09:06:14 2015 -Date of summary: Mon Nov 9 09:06:14 2015 +Date of fit: Mon Nov 9 10:12:09 2015 +Date of summary: Mon Nov 9 10:12:09 2015 Equations: d_parent = - k_parent_sink * parent - k_parent_m1 * parent @@ -144,7 +144,7 @@ d_m1 = + k_parent_m1 * parent - k_m1_sink * m1 Model predictions using solution type deSolve -Fitted with method Port using 153 model solutions performed in 0.619 s +Fitted with method Port using 153 model solutions performed in 0.632 s Weighting: none diff --git a/inst/web/vignettes/FOCUS_Z.pdf b/inst/web/vignettes/FOCUS_Z.pdf Binary files differindex 1234de20..31480019 100644 --- a/inst/web/vignettes/FOCUS_Z.pdf +++ b/inst/web/vignettes/FOCUS_Z.pdf diff --git a/inst/web/vignettes/compiled_models.html b/inst/web/vignettes/compiled_models.html index 92919da9..7722d95a 100644 --- a/inst/web/vignettes/compiled_models.html +++ b/inst/web/vignettes/compiled_models.html @@ -99,18 +99,18 @@ smb.1 <- summary(mb.1)[-1] rownames(smb.1) <- c("deSolve, not compiled", "Eigenvalue based", "deSolve, compiled") print(smb.1)</code></pre> <pre><code>## min lq mean median uq -## deSolve, not compiled 9307.3194 9319.9546 9332.8171 9332.5899 9345.5659 -## Eigenvalue based 855.3608 855.8081 869.4725 856.2555 876.5283 -## deSolve, compiled 686.6143 687.9256 698.0279 689.2369 703.7346 +## deSolve, not compiled 9442.5119 9447.2060 9458.3420 9451.9001 9466.2571 +## Eigenvalue based 868.6312 872.4552 895.3422 876.2792 908.6977 +## deSolve, compiled 691.9663 697.5653 701.1004 703.1643 705.6674 ## max neval cld -## deSolve, not compiled 9358.5420 3 c -## Eigenvalue based 896.8012 3 b -## deSolve, compiled 718.2324 3 a</code></pre> -<p>We see that using the compiled model is by a factor of 13.5 faster than using the R version with the default ode solver, and it is even faster than the Eigenvalue based solution implemented in R which does not need iterative solution of the ODEs:</p> +## deSolve, not compiled 9480.6141 3 c +## Eigenvalue based 941.1163 3 b +## deSolve, compiled 708.1706 3 a</code></pre> +<p>We see that using the compiled model is by a factor of 13.4 faster than using the R version with the default ode solver, and it is even faster than the Eigenvalue based solution implemented in R which does not need iterative solution of the ODEs:</p> <pre class="r"><code>smb.1["median"]/smb.1["deSolve, compiled", "median"]</code></pre> <pre><code>## median -## deSolve, not compiled 13.540468 -## Eigenvalue based 1.242324 +## deSolve, not compiled 13.441951 +## Eigenvalue based 1.246194 ## deSolve, compiled 1.000000</code></pre> </div> <div id="benchmark-for-a-model-that-can-not-be-solved-with-eigenvalues" class="section level2"> @@ -127,17 +127,17 @@ print(smb.1)</code></pre> smb.2 <- summary(mb.2)[-1] rownames(smb.2) <- c("deSolve, not compiled", "deSolve, compiled") print(smb.2)</code></pre> -<pre><code>## min lq mean median uq -## deSolve, not compiled 20.130709 20.147223 20.180429 20.163737 20.205289 -## deSolve, compiled 1.235864 1.255748 1.267458 1.275632 1.283255 -## max neval cld -## deSolve, not compiled 20.246841 3 b -## deSolve, compiled 1.290878 3 a</code></pre> +<pre><code>## min lq mean median uq +## deSolve, not compiled 20.444632 20.48824 20.557595 20.531857 20.614077 +## deSolve, compiled 1.251733 1.25179 1.275227 1.251846 1.286973 +## max neval cld +## deSolve, not compiled 20.6963 3 b +## deSolve, compiled 1.3221 3 a</code></pre> <pre class="r"><code>smb.2["median"]/smb.2["deSolve, compiled", "median"]</code></pre> <pre><code>## median -## deSolve, not compiled 15.80686 +## deSolve, not compiled 16.40126 ## deSolve, compiled 1.00000</code></pre> -<p>Here we get a performance benefit of a factor of 15.8 using the version of the differential equation model compiled from C code using the inline package!</p> +<p>Here we get a performance benefit of a factor of 16.4 using the version of the differential equation model compiled from C code using the inline package!</p> <p>This vignette was built with mkin 0.9.41 on</p> <pre><code>## R version 3.2.2 (2015-08-14) ## Platform: x86_64-pc-linux-gnu (64-bit) diff --git a/inst/web/vignettes/mkin.pdf b/inst/web/vignettes/mkin.pdf Binary files differindex 9c1a03f3..9f9f9af0 100644 --- a/inst/web/vignettes/mkin.pdf +++ b/inst/web/vignettes/mkin.pdf |