Running ‘testthat.R’ [377s/318s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(patrick)
  > library(statsExpressions)
  > 
  > test_check("statsExpressions")
  Starting 2 test processes.
  Saving _problems/test-corr-test-122.R
  Saving _problems/test-one-two-sample-dataframes-92.R
  Saving _problems/test-pairwise-comparisons-208.R
  Saving _problems/test-pairwise-comparisons-273.R
  Saving _problems/test-pairwise-comparisons-295.R
  [ FAIL 5 | WARN 0 | SKIP 65 | PASS 19 ]
  
  ══ Skipped tests (65) ══════════════════════════════════════════════════════════
  • On CRAN (44): 'test-centrality-description.R:1:1',
    'test-centrality-description.R:49:1', 'test-corr-test.R:3:1',
    'test-corr-test.R:39:1', 'test-corr-test.R:74:1',
    'test-contingency-table.R:1:1', 'test-contingency-table.R:49:1',
    'test-contingency-table.R:108:1', 'test-long-to-wide-converter.R:58:1',
    'test-one-sample.R:10:3', 'test-one-sample.R:10:3', 'test-one-sample.R:10:3',
    'test-one-sample.R:10:3', 'test-one-sample.R:10:3', 'test-one-sample.R:10:3',
    'test-one-sample.R:10:3', 'test-one-sample.R:10:3', 'test-one-sample.R:10:3',
    'test-one-sample.R:10:3', 'test-one-sample.R:10:3', 'test-one-sample.R:10:3',
    'test-oneway-anova-parametric.R:1:1', 'test-oneway-anova-parametric.R:35:1',
    'test-oneway-anova-nonparametric.R:5:1',
    'test-oneway-anova-nonparametric.R:41:1', 'test-pairwise-comparisons.R:3:1',
    'test-pairwise-comparisons.R:98:1', 'test-pairwise-comparisons.R:131:1',
    'test-pairwise-comparisons.R:318:1', 'test-tidy-model-expressions.R:1:1',
    'test-tidy-model-expressions.R:57:1', 'test-tidy-model-expressions.R:78:1',
    'test-two-sample-nonparametric.R:1:1',
    'test-two-sample-nonparametric.R:22:1', 'test-two-sample-parametric.R:1:1',
    'test-two-sample-parametric.R:23:1', 'test-two-sample-parametric.R:45:1',
    'test-two-sample-parametric.R:66:1', 'test-two-sample-robust.R:3:1',
    'test-two-sample-robust.R:25:1', 'test-two-sample-robust.R:45:1',
    'test-two-sample-robust.R:68:1', 'test-oneway-anova-robust.R:1:1',
    'test-oneway-anova-robust.R:40:1'
  • On Linux (1): 'test-centrality-description.R:27:5'
  • Skipping on R-devel due to summary() format changes (1):
    'test-long-to-wide-converter.R:6:5'
  • {Matrix} is not installed. (15): 'test-contingency-table.R:162:5',
    'test-contingency-table.R:189:5', 'test-oneway-anova-bayes.R:13:5',
    'test-oneway-anova-bayes.R:43:5', 'test-oneway-anova-bayes.R:103:5',
    'test-oneway-anova-bayes.R:140:5', 'test-one-sample.R:14:7',
    'test-one-sample.R:14:7', 'test-one-sample.R:14:7', 'test-one-sample.R:14:7',
    'test-oneway-anova-parametric.R:57:5', 'test-oneway-anova-parametric.R:80:5',
    'test-two-sample-bayes.R:5:5', 'test-two-sample-bayes.R:24:5',
    'test-two-sample-bayes.R:55:5'
  • {metaBMA} cannot be loaded (1): 'test-meta-random-bayes.R:4:5'
  • {metafor} cannot be loaded (1): 'test-meta-random-parametric.R:4:5'
  • {metaplus} cannot be loaded (1): 'test-meta-random-robust.R:4:5'
  • {survival} cannot be loaded (1): 'test-tidy-model-expressions.R:34:3'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-corr-test.R:115:5'): corr_test works - Bayesian ────────────────
  Error: Package `BayesFactor` required for this function to work.
    Please install it by running `install.packages("BayesFactor")`.
  Backtrace:
      ▆
   1. ├─statsExpressions::corr_test(...) at test-corr-test.R:115:5
   2. │ ├─... %>% ...
   3. │ └─correlation::correlation(...)
   4. │   └─correlation:::.correlation(...)
   5. │     └─correlation::cor_test(...)
   6. │       └─correlation:::.cor_test_bayes(...)
   7. │         └─insight::check_if_installed("BayesFactor")
   8. ├─dplyr::mutate(...)
   9. └─insight::standardize_names(., style = "broom")
  ── Error ('test-one-two-sample-dataframes.R:82:5'):  parametric t-tests ────────
  <purrr_error_indexed/rlang_error/error/condition>
  Error in `pmap(.l, .f, ...)`: i In index: 1.
  Caused by error in `loadNamespace()`:
  ! there is no package called 'Matrix'
  Backtrace:
       ▆
    1. ├─purrr::pmap_dfr(...) at test-one-two-sample-dataframes.R:82:5
    2. │ └─purrr::pmap(.l, .f, ...)
    3. │   └─purrr:::pmap_("list", .l, .f, ..., .progress = .progress)
    4. │     ├─purrr:::with_indexed_errors(...)
    5. │     │ └─base::withCallingHandlers(...)
    6. │     ├─purrr:::call_with_cleanup(...)
    7. │     └─statsExpressions (local) .f(...)
    8. ├─base::loadNamespace(x)
    9. │ ├─base::namespaceImportFrom(...)
   10. │ │ └─base::asNamespace(ns)
   11. │ └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   12. │   ├─base::namespaceImportFrom(...)
   13. │   │ └─base::asNamespace(ns)
   14. │   └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   15. │     ├─base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
   16. │     │ └─base (local) withOneRestart(expr, restarts[[1L]])
   17. │     │   └─base (local) doWithOneRestart(return(expr), restart)
   18. │     └─base::stop(cond)
   19. └─purrr (local) `<fn>`(`<pckgNtFE>`)
   20.   └─cli::cli_abort(...)
   21.     └─rlang::abort(...)
  ── Error ('test-pairwise-comparisons.R:202:5'): `pairwise_comparisons()` works for within-subjects design - NAs ──
  <purrr_error_indexed/rlang_error/error/condition>
  Error in `map(.x, .f, ...)`: i In index: 1.
  Caused by error in `loadNamespace()`:
  ! there is no package called 'Matrix'
  Backtrace:
       ▆
    1. ├─statsExpressions::pairwise_comparisons(...) at test-pairwise-comparisons.R:202:5
    2. │ ├─... %>% ...
    3. │ └─purrr::map_dfr(...)
    4. │   └─purrr::map(.x, .f, ...)
    5. │     └─purrr:::map_("list", .x, .f, ..., .progress = .progress)
    6. │       ├─purrr:::with_indexed_errors(...)
    7. │       │ └─base::withCallingHandlers(...)
    8. │       ├─purrr:::call_with_cleanup(...)
    9. │       └─statsExpressions (local) .f(.x[[i]], ...)
   10. │         └─statsExpressions::two_sample_test(...)
   11. │           ├─... %>% tidy_model_parameters(ci = conf.level)
   12. │           └─rlang::exec(BayesFactor::ttestBF, rscale = bf.prior, !!!.f.args)
   13. ├─dplyr::mutate(...)
   14. ├─dplyr::filter(., term == "Difference")
   15. ├─statsExpressions::tidy_model_parameters(., ci = conf.level)
   16. │ ├─... %>% ...
   17. │ └─parameters::model_parameters(model, verbose = FALSE, ...)
   18. ├─dplyr::mutate(...)
   19. ├─tidyr::fill(., matches("^prior|^bf"), .direction = "updown")
   20. ├─dplyr::rename_with(., recode, bayes.factor = "bf10")
   21. ├─dplyr::rename_all(...)
   22. │ └─dplyr::tbl_vars(.tbl)
   23. │   ├─dplyr:::new_sel_vars(tbl_vars_dispatch(x), group_vars(x))
   24. │   │ └─base::structure(...)
   25. │   └─dplyr:::tbl_vars_dispatch(x)
   26. ├─insight::standardize_names(., style = "broom")
   27. ├─dplyr::select(., -matches("Difference"))
   28. ├─dplyr::mutate(., conf.method = attr(., "ci_method"))
   29. ├─base::loadNamespace(x)
   30. │ ├─base::namespaceImportFrom(...)
   31. │ │ └─base::asNamespace(ns)
   32. │ └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   33. │   ├─base::namespaceImportFrom(...)
   34. │   │ └─base::asNamespace(ns)
   35. │   └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   36. │     ├─base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
   37. │     │ └─base (local) withOneRestart(expr, restarts[[1L]])
   38. │     │   └─base (local) doWithOneRestart(return(expr), restart)
   39. │     └─base::stop(cond)
   40. └─purrr (local) `<fn>`(`<pckgNtFE>`)
   41.   └─cli::cli_abort(...)
   42.     └─rlang::abort(...)
  ── Error ('test-pairwise-comparisons.R:267:5'): `pairwise_comparisons()` works for within-subjects design - without NAs ──
  <purrr_error_indexed/rlang_error/error/condition>
  Error in `map(.x, .f, ...)`: i In index: 1.
  Caused by error in `loadNamespace()`:
  ! there is no package called 'Matrix'
  Backtrace:
       ▆
    1. ├─statsExpressions::pairwise_comparisons(...) at test-pairwise-comparisons.R:267:5
    2. │ ├─... %>% ...
    3. │ └─purrr::map_dfr(...)
    4. │   └─purrr::map(.x, .f, ...)
    5. │     └─purrr:::map_("list", .x, .f, ..., .progress = .progress)
    6. │       ├─purrr:::with_indexed_errors(...)
    7. │       │ └─base::withCallingHandlers(...)
    8. │       ├─purrr:::call_with_cleanup(...)
    9. │       └─statsExpressions (local) .f(.x[[i]], ...)
   10. │         └─statsExpressions::two_sample_test(...)
   11. │           ├─... %>% tidy_model_parameters(ci = conf.level)
   12. │           └─rlang::exec(BayesFactor::ttestBF, rscale = bf.prior, !!!.f.args)
   13. ├─dplyr::mutate(...)
   14. ├─dplyr::filter(., term == "Difference")
   15. ├─statsExpressions::tidy_model_parameters(., ci = conf.level)
   16. │ ├─... %>% ...
   17. │ └─parameters::model_parameters(model, verbose = FALSE, ...)
   18. ├─dplyr::mutate(...)
   19. ├─tidyr::fill(., matches("^prior|^bf"), .direction = "updown")
   20. ├─dplyr::rename_with(., recode, bayes.factor = "bf10")
   21. ├─dplyr::rename_all(...)
   22. │ └─dplyr::tbl_vars(.tbl)
   23. │   ├─dplyr:::new_sel_vars(tbl_vars_dispatch(x), group_vars(x))
   24. │   │ └─base::structure(...)
   25. │   └─dplyr:::tbl_vars_dispatch(x)
   26. ├─insight::standardize_names(., style = "broom")
   27. ├─dplyr::select(., -matches("Difference"))
   28. ├─dplyr::mutate(., conf.method = attr(., "ci_method"))
   29. ├─base::loadNamespace(x)
   30. │ ├─base::namespaceImportFrom(...)
   31. │ │ └─base::asNamespace(ns)
   32. │ └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   33. │   ├─base::namespaceImportFrom(...)
   34. │   │ └─base::asNamespace(ns)
   35. │   └─base::loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
   36. │     ├─base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
   37. │     │ └─base (local) withOneRestart(expr, restarts[[1L]])
   38. │     │   └─base (local) doWithOneRestart(return(expr), restart)
   39. │     └─base::stop(cond)
   40. └─purrr (local) `<fn>`(`<pckgNtFE>`)
   41.   └─cli::cli_abort(...)
   42.     └─rlang::abort(...)
  ── Error ('test-pairwise-comparisons.R:284:5'): works with subject id ──────────
  <purrr_error_indexed/rlang_error/error/condition>
  Error in `pmap(.l, .f, ...)`: i In index: 4.
  Caused by error in `map()`:
  i In index: 1.
  Caused by error in `loadNamespace()`:
  ! there is no package called 'Matrix'
  
  [ FAIL 5 | WARN 0 | SKIP 65 | PASS 19 ]
  Error:
  ! Test failures.
  Execution halted