aboutsummaryrefslogtreecommitdiff
path: root/tests/testthat
diff options
context:
space:
mode:
Diffstat (limited to 'tests/testthat')
-rw-r--r--tests/testthat/print_mmkin_biphasic_mixed.txt4
-rw-r--r--tests/testthat/print_nlme_biphasic.txt6
-rw-r--r--tests/testthat/summary_nlme_biphasic_s.txt40
-rw-r--r--tests/testthat/test_mixed.R4
4 files changed, 27 insertions, 27 deletions
diff --git a/tests/testthat/print_mmkin_biphasic_mixed.txt b/tests/testthat/print_mmkin_biphasic_mixed.txt
index 62e485ac..3d92b120 100644
--- a/tests/testthat/print_mmkin_biphasic_mixed.txt
+++ b/tests/testthat/print_mmkin_biphasic_mixed.txt
@@ -21,6 +21,6 @@ OK: No warnings
Mean fitted parameters:
parent_0 log_k_m1 f_parent_qlogis log_k1 log_k2
- 100.70048940 -6.29941397 -0.07845907 -3.09354444 -3.95368996
+ 100.700 -6.299 -0.078 -3.094 -3.954
g_qlogis
- 0.02729554
+ 0.027
diff --git a/tests/testthat/print_nlme_biphasic.txt b/tests/testthat/print_nlme_biphasic.txt
index 9ea84d44..98895d3a 100644
--- a/tests/testthat/print_nlme_biphasic.txt
+++ b/tests/testthat/print_nlme_biphasic.txt
@@ -16,14 +16,14 @@ Log-likelihood: -1343
Fixed effects:
list(parent_0 ~ 1, log_k_m1 ~ 1, f_parent_qlogis ~ 1, log_k1 ~ 1, log_k2 ~ 1, g_qlogis ~ 1)
parent_0 log_k_m1 f_parent_qlogis log_k1 log_k2
- 100.365 -6.231 -0.078 -3.224 -4.098
+ 100.37 -6.23 -0.08 -3.22 -4.10
g_qlogis
- -0.105
+ -0.10
Random effects:
Formula: list(parent_0 ~ 1, log_k_m1 ~ 1, f_parent_qlogis ~ 1, log_k1 ~ 1, log_k2 ~ 1, g_qlogis ~ 1)
Level: ds
Structure: Diagonal
parent_0 log_k_m1 f_parent_qlogis log_k1 log_k2 g_qlogis Residual
-StdDev: 1.1 0.00017 0.28 0.74 0.82 0.28 2.7
+StdDev: 1 2e-04 0.3 0.7 0.8 0.3 3
diff --git a/tests/testthat/summary_nlme_biphasic_s.txt b/tests/testthat/summary_nlme_biphasic_s.txt
index 1e4c3c14..f9171748 100644
--- a/tests/testthat/summary_nlme_biphasic_s.txt
+++ b/tests/testthat/summary_nlme_biphasic_s.txt
@@ -23,9 +23,9 @@ Variance model: Constant variance
Mean of starting values for individual parameters:
parent_0 log_k_m1 f_parent_qlogis log_k1 log_k2
- 100.700 -6.299 -0.078 -3.094 -3.954
+ 100.70 -6.30 -0.08 -3.09 -3.95
g_qlogis
- 0.027
+ 0.03
Fixed degradation parameter values:
value type
@@ -37,13 +37,13 @@ Results:
2711 2766 -1343
Optimised, transformed parameters with symmetric confidence intervals:
- lower est. upper
-parent_0 99.50 100.365 101.229
-log_k_m1 -6.53 -6.231 -5.936
-f_parent_qlogis -0.24 -0.078 0.084
-log_k1 -3.61 -3.224 -2.839
-log_k2 -4.52 -4.098 -3.677
-g_qlogis -0.38 -0.105 0.172
+ lower est. upper
+parent_0 99.5 100.37 101.23
+log_k_m1 -6.5 -6.23 -5.94
+f_parent_qlogis -0.2 -0.08 0.08
+log_k1 -3.6 -3.22 -2.84
+log_k2 -4.5 -4.10 -3.68
+g_qlogis -0.4 -0.10 0.17
Correlation:
prnt_0 lg_k_1 f_prn_ log_k1 log_k2
@@ -58,22 +58,22 @@ Random effects:
Level: ds
Structure: Diagonal
parent_0 log_k_m1 f_parent_qlogis log_k1 log_k2 g_qlogis Residual
-StdDev: 1.1 0.00017 0.28 0.74 0.82 0.28 2.7
+StdDev: 1 2e-04 0.3 0.7 0.8 0.3 3
Backtransformed parameters with asymmetric confidence intervals:
- lower est. upper
-parent_0 1.0e+02 100.365 1.0e+02
-k_m1 1.5e-03 0.002 2.6e-03
-f_parent_to_m1 4.4e-01 0.480 5.2e-01
-k1 2.7e-02 0.040 5.9e-02
-k2 1.1e-02 0.017 2.5e-02
-g 4.1e-01 0.474 5.4e-01
+ lower est. upper
+parent_0 1e+02 1e+02 1e+02
+k_m1 1e-03 2e-03 3e-03
+f_parent_to_m1 4e-01 5e-01 5e-01
+k1 3e-02 4e-02 6e-02
+k2 1e-02 2e-02 3e-02
+g 4e-01 5e-01 5e-01
Resulting formation fractions:
- ff
-parent_m1 0.48
-parent_sink 0.52
+ ff
+parent_m1 0.5
+parent_sink 0.5
Estimated disappearance times:
DT50 DT90 DT50back DT50_k1 DT50_k2
diff --git a/tests/testthat/test_mixed.R b/tests/testthat/test_mixed.R
index b9713c6e..ef73f21d 100644
--- a/tests/testthat/test_mixed.R
+++ b/tests/testthat/test_mixed.R
@@ -46,7 +46,7 @@ test_that("Parent only models can be fitted using nonlinear mixed effects models
test_that("Print methods work", {
expect_known_output(print(mmkin_biphasic_mixed, digits = 2), "print_mmkin_biphasic_mixed.txt")
- expect_known_output(print(nlme_biphasic, digits = 2), "print_nlme_biphasic.txt")
+ expect_known_output(print(nlme_biphasic, digits = 1), "print_nlme_biphasic.txt")
expect_known_output(print(sfo_saemix_1, digits = 1), "print_sfo_saemix_1.txt")
})
@@ -60,7 +60,7 @@ test_that("nlme results are reproducible", {
test_summary$date.summary <- "Dummy date for testing"
test_summary$time <- c(elapsed = "test time 0")
- expect_known_output(print(test_summary, digits = 2), "summary_nlme_biphasic_s.txt")
+ expect_known_output(print(test_summary, digits = 1), "summary_nlme_biphasic_s.txt")
dfop_sfo_pop <- as.numeric(dfop_sfo_pop)
ci_dfop_sfo_n <- summary(nlme_biphasic)$confint_back

Contact - Imprint