diff options
author | Johannes Ranke <jranke@uni-bremen.de> | 2020-05-11 13:43:40 +0200 |
---|---|---|
committer | Johannes Ranke <jranke@uni-bremen.de> | 2020-05-11 13:43:40 +0200 |
commit | b36ae3d710858ee3ff2907eb2d780e0dff48a4f3 (patch) | |
tree | b9e075d38233106465481c25b0a777ef043fb1c7 /tests/testthat/test_from_max_mean.R | |
parent | 576fbc9d86f4db3d1be2fbd4e97b3fcd58f43c2b (diff) |
Analytical solutions for all SFO variants
Diffstat (limited to 'tests/testthat/test_from_max_mean.R')
-rw-r--r-- | tests/testthat/test_from_max_mean.R | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/testthat/test_from_max_mean.R b/tests/testthat/test_from_max_mean.R index 002b39e2..5a66c1ef 100644 --- a/tests/testthat/test_from_max_mean.R +++ b/tests/testthat/test_from_max_mean.R @@ -6,15 +6,15 @@ test_that("Fitting from maximum mean value works", { expect_error(mkinfit(SFO_SFO, FOCUS_2006_D, from_max_mean = TRUE), "only implemented for models with a single observed variable"), "Observations with value of zero were removed") - + # We can either explicitly create a model for m1, or subset the data SFO_m1 <- mkinmod(m1 = mkinsub("SFO")) - f.1 <- expect_warning(mkinfit(SFO_m1, FOCUS_2006_D, from_max_mean = TRUE, quiet = TRUE)) - expect_equivalent(endpoints(f.1)$distimes["m1", ], c(170.8, 567.5), - scale = 1, tolerance = 0.1) + f.1 <- mkinfit(SFO_m1, FOCUS_D, from_max_mean = TRUE, quiet = TRUE) + expect_equivalent(endpoints(f.1)$distimes["m1", ], c(170.8, 567.5), + scale = 1, tolerance = 0.1) - f.2 <- expect_warning(mkinfit("SFO", subset(FOCUS_2006_D, name == "m1"), - from_max_mean = TRUE, quiet = TRUE)) - expect_equivalent(endpoints(f.2)$distimes["m1", ], c(170.8, 567.5), + f.2 <- mkinfit("SFO", subset(FOCUS_D, name == "m1"), + from_max_mean = TRUE, quiet = TRUE) + expect_equivalent(endpoints(f.2)$distimes["m1", ], c(170.8, 567.5), scale = 1, tolerance = 0.1) }) |