Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
strengejacke committed Nov 26, 2024
1 parent 0946989 commit 7e78539
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/testthat/test-marginaleffects.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
skip_if_not_installed("marginaleffects", minimum_version = "0.24.0")
skip_if_not_installed("marginaleffects", minimum_version = "1.0.0")
skip_if_not_installed("rstanarm")

test_that("marginaleffects()", {
Expand All @@ -7,7 +7,7 @@ test_that("marginaleffects()", {
model <- marginaleffects::avg_slopes(x, newdata = insight::get_datagrid(x, by = "Species"), variables = "Petal.Length")

Check warning on line 7 in tests/testthat/test-marginaleffects.R

View workflow job for this annotation

GitHub Actions / lint-changed-files / lint-changed-files

file=tests/testthat/test-marginaleffects.R,line=7,col=121,[line_length_linter] Lines should not be more than 120 characters. This line is 121 characters.
out <- parameters(model)
expect_identical(nrow(out), 1L)
cols <- c("Parameter", "Coefficient", "SE", "Statistic", "p", "S", "CI", "CI_low", "CI_high")
cols <- c("Parameter", "Comparison", "Coefficient", "SE", "Statistic", "p", "S", "CI", "CI_low", "CI_high")
expect_true(all(cols %in% colnames(out)))
out <- model_parameters(model, exponentiate = TRUE)
expect_equal(out$Coefficient, 1.394, tolerance = 1e-3)
Expand Down

0 comments on commit 7e78539

Please sign in to comment.