Skip to content

Commit

Permalink
Merge pull request #51 from ncn-foreigners/main
Browse files Browse the repository at this point in the history
pulling changes from main
  • Loading branch information
Piotr Chlebicki authored Jul 15, 2024
2 parents b57f497 + b479e9c commit f92547f
Showing 1 changed file with 38 additions and 3 deletions.
41 changes: 38 additions & 3 deletions inst/tinytest/test_singleRcapture.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ expect_silent(
)

expect_silent(
estimatePopsize(
dd <- estimatePopsize(
formula = TOTAL_SUB ~ .,
model = "zotnegbin",
method = "optim",
Expand All @@ -29,6 +29,13 @@ expect_silent(
)
)

expect_silent(
predict(
dd,
type = "mean"
)
)

expect_silent(
irls <- estimatePopsize(
formula = TOTAL_SUB ~ .,
Expand Down Expand Up @@ -71,6 +78,13 @@ expect_silent(
)
)

expect_silent(
predict(
ch,
type = "mean"
)
)

expect_equivalent(
ch$populationSize$pointEstimate,
21657,
Expand All @@ -97,6 +111,13 @@ expect_silent(
)
)

expect_silent(
predict(
zl,
type = "mean"
)
)

expect_silent(
zl2 <- estimatePopsize(
formula = capture ~ 1,
Expand Down Expand Up @@ -260,7 +281,7 @@ expect_error(
if (isTRUE(tolower(Sys.getenv("TEST_SINGLERCAPTURE_MULTICORE_DEVELOPER")) == "true")) {
set.seed(123)
expect_silent(
estimatePopsize(
xx <- estimatePopsize(
formula = TOTAL_SUB ~ .,
data = farmsubmission,
model = "zotpoisson",
Expand All @@ -278,7 +299,14 @@ if (isTRUE(tolower(Sys.getenv("TEST_SINGLERCAPTURE_MULTICORE_DEVELOPER")) == "tr
)

expect_silent(
estimatePopsize(
predict(
xx,
type = "mean"
)
)

expect_silent(
xx <- estimatePopsize(
formula = capture ~ gender,
data = netherlandsimmigrant,
model = "zotgeom",
Expand All @@ -293,6 +321,13 @@ if (isTRUE(tolower(Sys.getenv("TEST_SINGLERCAPTURE_MULTICORE_DEVELOPER")) == "tr
)
)

expect_silent(
predict(
xx,
type = "mean"
)
)

expect_silent(
estimatePopsize(
formula = TOTAL_SUB ~ .,
Expand Down

0 comments on commit f92547f

Please sign in to comment.