aboutsummaryrefslogtreecommitdiff
path: root/tests/testthat/setup_script.R
diff options
context:
space:
mode:
authorJohannes Ranke <jranke@uni-bremen.de>2022-03-07 12:03:40 +0100
committerJohannes Ranke <jranke@uni-bremen.de>2022-03-07 14:55:21 +0100
commit7035cde3a53781721fe15a8893fdf328c789bdd2 (patch)
treea1e4929faf9d645caedc0ed4dcc5036252497c63 /tests/testthat/setup_script.R
parent77c248ca40b82ec00a756cd82f12968131f78959 (diff)
Remove nlmixr interface for release of mkin 1.1.0
I am postponing my attempts to get the nlmixr interface to CRAN, given some problems with nlmixr using R-devel under Windows, see https://github.com/nlmixrdevelopment/nlmixr/issues/596 and https://github.com/r-hub/rhub/issues/512, which is fixed by the removal of nlmixr from the testsuite. For the tests to be more platform independent, the biphasic mixed effects models test dataset was defined in a way that fitting should be more robust (less ill-defined).
Diffstat (limited to 'tests/testthat/setup_script.R')
-rw-r--r--tests/testthat/setup_script.R14
1 files changed, 4 insertions, 10 deletions
diff --git a/tests/testthat/setup_script.R b/tests/testthat/setup_script.R
index ec96fbc2..10696082 100644
--- a/tests/testthat/setup_script.R
+++ b/tests/testthat/setup_script.R
@@ -160,8 +160,8 @@ DFOP_SFO <- mkinmod(
m1 = mkinsub("SFO"),
quiet = TRUE)
dfop_sfo_pop <- list(parent_0 = 100,
- k_m1 = 0.005, f_parent_to_m1 = 0.5,
- k1 = 0.05, k2 = 0.01, g = 0.5)
+ k_m1 = 0.007, f_parent_to_m1 = 0.5,
+ k1 = 0.1, k2 = 0.02, g = 0.5)
syn_biphasic_parms <- as.matrix(data.frame(
k1 = rlnorm(n_biphasic, log(dfop_sfo_pop$k1), log_sd),
k2 = rlnorm(n_biphasic, log(dfop_sfo_pop$k2), log_sd),
@@ -186,11 +186,12 @@ ds_biphasic <- lapply(ds_biphasic_mean, function(ds) {
mmkin_sfo_1 <- mmkin("SFO", ds_sfo, quiet = TRUE, error_model = "tc", cores = n_cores)
mmkin_dfop_1 <- mmkin("DFOP", ds_dfop, quiet = TRUE, cores = n_cores)
mmkin_biphasic <- mmkin(list("DFOP-SFO" = DFOP_SFO), ds_biphasic, quiet = TRUE, cores = n_cores,
+ control = list(eval.max = 500, iter.max = 400),
error_model = "tc")
# nlme
dfop_nlme_1 <- nlme(mmkin_dfop_1)
-nlme_biphasic <- nlme(mmkin_biphasic)
+nlme_biphasic <- suppressWarnings(nlme(mmkin_biphasic))
# saemix
sfo_saem_1 <- saem(mmkin_sfo_1, quiet = TRUE, transformations = "saemix")
@@ -201,13 +202,6 @@ dfop_saemix_2 <- saem(mmkin_dfop_1, quiet = TRUE, transformations = "saemix")
saem_biphasic_m <- saem(mmkin_biphasic, transformations = "mkin", quiet = TRUE)
saem_biphasic_s <- saem(mmkin_biphasic, transformations = "saemix", quiet = TRUE)
-# nlmixr saem
-tmp <- suppressMessages(capture.output(nlmixr_saem_biphasic <- nlmixr(mmkin_biphasic, est = "saem",
- control = nlmixr::saemControl(nBurn = 300, nEm = 100, nmc = 9, print = 0))))
-# The FOCEI fit takes too long...
-#tmp <- capture_output(nlmixr_focei_biphasic <- nlmixr(mmkin_biphasic, est = "focei",
-# control = nlmixr::foceiControl(print = 0)))
-
# UBA datasets
ds_uba <- lapply(experimental_data_for_UBA_2019[6:10],
function(x) subset(x$data[c("name", "time", "value")]))

Contact - Imprint