You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi team, thanks for the great work. I love how your packages make it easier to process the outputs of models. I use these teaching a large 2nd year university course with 170 students. :)
I'm encountering a strange error and not sure how to solve or diagnose this. When I run estimate_contrasts with the basic example I get a cryptic error. I'm running the latest version on max OSX, R and packages. Moreover it used to work, so this behaviour has appeared in the last few days. Not sure how or why.
I've also included the stack call below. I'm a reasonably advanced user and a bit perplexed
The below was run in a clean R session. It occurs whether running in rstduio or terminal,
> library(modelbased)
> model <- lm(Sepal.Width ~ Species, data = iris)
> estimate_contrasts(model)
We selected `contrast=c("Species")`.
Error: Sorry, calculating marginal contrasts failed with following error:
Assertion failed. One of the following must apply: * checkmate::check_character(hypothesis): Must be of type
'character', not 'formula' * checkmate::check_choice(hypothesis): Must be element of set
{'pairwise','reference','sequential','meandev','meanotherdev','revpairwise','revreference','revsequential'}, but is * not atomic scalar * checkmate::check_numeric(hypothesis): Must
be of type 'numeric', not 'formula' * checkmate::check_matrix(hypothesis): Must be of type 'matrix', not 'formula' * checkmate::check_function(hypothesis): Must be a function, not
'formula' * checkmate::check_null(hypothesis): Must be NULL
> sessionInfo()
R version 4.4.2 (2024-10-31)
Platform: aarch64-apple-darwin20
Running under: macOS Sequoia 15.3.1
Matrix products: default
BLAS: /Library/Frameworks/R.framework/Versions/4.4-arm64/Resources/lib/libRblas.0.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.4-arm64/Resources/lib/libRlapack.dylib; LAPACK version 3.12.0
locale:
[1] en_US.UTF-8/en_AU.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
time zone: Australia/Sydney
tzcode source: internal
attached base packages:
[1] stats graphics grDevices datasets utils methods base
other attached packages:
[1] modelbased_0.9.0 datapasta_3.1.0
loaded via a namespace (and not attached):
[1] marginaleffects_0.20.1 compiler_4.4.2 backports_1.5.0 generics_0.1.3 cli_3.6.3.9002 datawizard_1.0.0 Rcpp_1.0.14 crayon_1.5.3.9000
[9] data.table_1.16.4 checkmate_2.3.2 insight_1.0.2 rlang_1.1.5 rdoc_0.1.0.9000
Stack
> options(error=recover)
> estimate_contrasts(model)
We selected `contrast=c("Species")`.
Error: Sorry, calculating marginal contrasts failed with following error:
Assertion failed. One of the following must apply: * checkmate::check_character(hypothesis): Must be of type
'character', not 'formula' * checkmate::check_choice(hypothesis): Must be element of set
{'pairwise','reference','sequential','meandev','meanotherdev','revpairwise','revreference','revsequential'}, but is * not atomic scalar * checkmate::check_numeric(hypothesis): Must
be of type 'numeric', not 'formula' * checkmate::check_matrix(hypothesis): Must be of type 'matrix', not 'formula' * checkmate::check_function(hypothesis): Must be a function, not
'formula' * checkmate::check_null(hypothesis): Must be NULL
Enter a frame number, or 0 to exit
1: estimate_contrasts(model)
2: estimate_contrasts.default(model)
3: get_marginalcontrasts(model, contrast = contrast, by = by, predict = predict, comparison = comparison, p_adjust = p_adjust, ci = ci, estimate = estimate, transform = transform, verbose = verbose,
4: estimate_means(model = model, by = unique(c(my_args$contrast, my_args$by)), ci = ci, hypothesis = my_args$comparison, predict = predict, backend = "marginaleffects", estimate = estimate, transfor
5: get_marginalmeans(model, by = by, predict = predict, ci = ci, estimate = estimate, transform = transform, verbose = verbose, ...)
6: .call_marginaleffects(fun_args)
7: insight::format_error(msg)
8: format_alert(..., type = "error")
The text was updated successfully, but these errors were encountered:
Hi team, thanks for the great work. I love how your packages make it easier to process the outputs of models. I use these teaching a large 2nd year university course with 170 students. :)
I'm encountering a strange error and not sure how to solve or diagnose this. When I run
estimate_contrasts
with the basic example I get a cryptic error. I'm running the latest version on max OSX, R and packages. Moreover it used to work, so this behaviour has appeared in the last few days. Not sure how or why.I've also included the stack call below. I'm a reasonably advanced user and a bit perplexed
The below was run in a clean R session. It occurs whether running in rstduio or terminal,
Stack
The text was updated successfully, but these errors were encountered: