Skip to content

Commit

Permalink
update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
strengejacke committed Oct 27, 2024
1 parent 871441d commit 00d20ee
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 10 deletions.
8 changes: 4 additions & 4 deletions tests/testthat/_snaps/complete_separation.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@
Code
print(out)
Output
Parameter | Log-Odds | SE | 95% CI | z | p
---------------------------------------------------------------
(Intercept) | -70.25 | 88.29 | [ , -16.06] | -0.80 | 0.426
qsec | 4.12 | 5.22 | [0.97, ] | 0.79 | 0.430
Parameter | Log-Odds | SE | 95% CI | z | p
------------------------------------------------------------------
(Intercept) | -51.19 | 19.62 | [-105.21, -22.47] | -2.61 | 0.009
qsec | 2.89 | 1.10 | [ 1.28, 5.93] | 2.63 | 0.009
Message
Uncertainty intervals (profile-likelihood) and p-values (two-tailed)
Expand Down
8 changes: 3 additions & 5 deletions tests/testthat/_snaps/printing.md
Original file line number Diff line number Diff line change
Expand Up @@ -361,9 +361,7 @@
Uncertainty intervals (equal-tailed) and p-values (two-tailed) computed
using a Wald t-distribution approximation.
This model has a log-transformed response variable, and exponentiated
parameters are reported.
A one-unit increase in the predictor is associated with multiplying the
outcome by that predictor's coefficient.
The model has a log-transformed response variable, and exponentiated
parameters are reported. A one-unit increase in the predictor is
associated with multiplying the outcome by that predictor's coefficient.

2 changes: 1 addition & 1 deletion tests/testthat/test-complete_separation.R
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ withr::with_options(
test_that("print warning about quasi complete separation", {
data(mtcars)
set.seed(323)
m_sep3 <- suppressWarnings(glm(vs ~ qsec, data = mtcars[sample.int(32, 15, replace = TRUE), ], family = binomial)) # nolint
m_sep3 <- suppressWarnings(glm(vs ~ qsec, data = mtcars[sample.int(32, 27, replace = TRUE), ], family = binomial)) # nolint
out <- model_parameters(m_sep3)
expect_snapshot(print(out))
})
Expand Down

0 comments on commit 00d20ee

Please sign in to comment.