mirror of
https://github.com/msberends/AMR.git
synced 2026-11-16 05:00:50 +01:00
add unit tests
This commit is contained in:
1 parent
a5a4354651
commit
967ee86757
2 files changed
+53
-4
No files matched your search
@@ -18,6 +18,7 @@ test_that("G-test works", {
|
||||
expected = 0.01787343,
|
||||
tolerance = 0.00000001)
|
||||
|
||||
|
||||
# INDEPENDENCE
|
||||
|
||||
x <- matrix(data = round(runif(4) * 100000, 0),
|
||||
@@ -26,4 +27,8 @@ test_that("G-test works", {
|
||||
expect_lt(g.test(x)$p.value,
|
||||
1)
|
||||
|
||||
expect_warning(g.test(x = c(772, 1611, 737),
|
||||
y = c(780, 1560, 780),
|
||||
rescale.p = TRUE))
|
||||
|
||||
})
|
||||
Reference in new issue
Block a user