aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohannes Ranke <jranke@uni-bremen.de>2019-03-04 10:36:53 +0100
committerJohannes Ranke <jranke@uni-bremen.de>2019-03-04 10:36:53 +0100
commitd3da24d4d7e616ba2c862905a1a57fc05f453746 (patch)
tree950f71987007d6498b7a2e547b8a38176c363b37
parentd0a358a8f4fd03c95536409523e492eb15726f44 (diff)
signif for DTx when printing nafta results
In order to be able to test cross-platform
-rw-r--r--R/nafta.R2
-rw-r--r--tests/testthat/NAFTA_SOP_Appendix_B.txt2
-rw-r--r--tests/testthat/NAFTA_SOP_Appendix_D.txt6
3 files changed, 5 insertions, 5 deletions
diff --git a/R/nafta.R b/R/nafta.R
index 0d8c6cb9..6a8ad42f 100644
--- a/R/nafta.R
+++ b/R/nafta.R
@@ -73,7 +73,7 @@ print.nafta <- function(x, quiet = TRUE, digits = 3, ...) {
print(x$parameters, digits = digits)
t_rep <- .evaluate_nafta_results(x$S, x$S_c, x$distimes, quiet = quiet)
cat("\nDTx values:\n")
- print(x$distimes, digits = digits)
+ print(signif(x$distimes, digits = digits))
cat("\nRepresentative half-life:\n")
print(t_rep)
}
diff --git a/tests/testthat/NAFTA_SOP_Appendix_B.txt b/tests/testthat/NAFTA_SOP_Appendix_B.txt
index e5479b88..26a340c5 100644
--- a/tests/testthat/NAFTA_SOP_Appendix_B.txt
+++ b/tests/testthat/NAFTA_SOP_Appendix_B.txt
@@ -29,7 +29,7 @@ DTx values:
DT50 DT90 DT50_rep
SFO 2.74 9.1 2.74
IORE 1.37 28.5 8.57
-DFOP 2.17 39.9 54.44
+DFOP 2.17 39.9 54.40
Representative half-life:
[1] 8.573302
diff --git a/tests/testthat/NAFTA_SOP_Appendix_D.txt b/tests/testthat/NAFTA_SOP_Appendix_D.txt
index 7ff2817c..1e846a16 100644
--- a/tests/testthat/NAFTA_SOP_Appendix_D.txt
+++ b/tests/testthat/NAFTA_SOP_Appendix_D.txt
@@ -27,9 +27,9 @@ g 2.88e-01 1.31e-04 1.78e-01 4.30e-01
DTx values:
DT50 DT90 DT50_rep
-SFO 407 1352 407
-IORE 541 5192060 1562966
-DFOP 429 2383 841
+SFO 407 1350 407
+IORE 541 5190000 1560000
+DFOP 429 2380 841
Representative half-life:
[1] 841.4096

Contact - Imprint