Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Kruskal-Wallis method #397

Merged
merged 7 commits into from
Nov 5, 2023
Merged

Add Kruskal-Wallis method #397

merged 7 commits into from
Nov 5, 2023

Conversation

rempsyc
Copy link
Member

@rempsyc rempsyc commented Oct 15, 2023

Closes #396


library(report)

x <- kruskal.test(airquality$Ozone ~ as.factor(airquality$Month))

report(x)
#> Warning: Missing values detected. NAs dropped.
#> Effect sizes were labelled following Field's (2013) recommendations.
#> 
#> The Kruskal-Wallis rank sum test testing the difference in ranks between
#> airquality$Ozone and as.factor(airquality$Month) suggests that the effect is
#> statistically significant, and large (Kruskal-Wallis chi2 = 29.27, p < .001;
#> Epsilon squared (rank) = 0.25, 95% CI [0.15, 1.00])

Created on 2023-10-15 with reprex v2.0.2

@rempsyc
Copy link
Member Author

rempsyc commented Oct 22, 2023

Waiting on #395 to be merged before fixing workflows here

@rempsyc rempsyc marked this pull request as draft October 23, 2023 00:52
@rempsyc
Copy link
Member Author

rempsyc commented Nov 5, 2023

@IndrajeetPatil I'm seeing errors that I don't understand. In DESCRIPTION file, I have (as suggested by Daniel):

Remotes: 
  easystats/insight,
  easystats/datawizard,
  easystats/parameters,
  easystats/effectsize,
  easystats/bayestestR,
  easystats/performance

So locally on Windows I ran easystats::install_latest() and updated all my CRAN packages to latest, and I get 0 errors, 0 warnings, 0 notes.

On GHA, check-readme fails but is a false positive (installation error); check-random-test-order fails for test-report.brmsfit.R although I have not changed this file and that it has a single test_that() call, and there is no information on the error; and test-coverage fails with

Error: Error: Failure in `C:/Users/runneradmin/AppData/Local/Temp/RtmpSOg0tv/R_LIBS7e4792a5e1/report/report-tests/testthat.Rout.fail`
       │ └─base::eval(expr, envir)
 14.               │   └─base::eval(expr, envir)
 15.               └─brms::do_call(rstan::stan_model, args)
 16.                 └─brms:::eval2(call, envir = args, enclos = envir)
 17.                   └─base::eval(expr, envir, ...)
 18.                     └─base::eval(expr, envir, ...)
 19.                       └─rstan (local) .fun(model_code = .x1)

So still related to brms, but locally I also have the latest brms version, and again, I haven't modified those files... 🤔


Edit: Also, R-CMD-check-strict also fails because of the following note:

Unknown, possibly misspelled, fields in DESCRIPTION:
    ‘Remotes’

So we're not allowed to use the Remotes field on GHA testing anymore? 🤔

@IndrajeetPatil
Copy link
Member

Also, R-CMD-check-strict also fails

This should be fixed now.

Copy link

codecov bot commented Nov 5, 2023

Codecov Report

Merging #397 (a4cfbd4) into main (f4c0697) will decrease coverage by 0.04%.
The diff coverage is 72.22%.

❗ Current head a4cfbd4 differs from pull request most recent head 0b7592a. Consider uploading reports for the commit 0b7592a to get more accurate results

@@            Coverage Diff             @@
##             main     #397      +/-   ##
==========================================
- Coverage   73.78%   73.74%   -0.04%     
==========================================
  Files          49       50       +1     
  Lines        3494     3546      +52     
==========================================
+ Hits         2578     2615      +37     
- Misses        916      931      +15     
Files Coverage Δ
R/report.htest.R 92.34% <100.00%> (+0.32%) ⬆️
R/report_htest_kruskal.R 65.90% <65.90%> (ø)

@rempsyc rempsyc marked this pull request as ready for review November 5, 2023 20:24
@rempsyc
Copy link
Member Author

rempsyc commented Nov 5, 2023

Thanks! All works now :) Except check-readme which I believe is a false positive:

 Backtrace:
  1. pak::lockfile_install(".github/pkg.lock")
  2. pak:::remote(function(...) { …
  3. err$throw(res$error)
  ---
  Subprocess backtrace:
   1. base::withCallingHandlers(cli_message = function(msg) { …
   2. get("lockfile_install_internal", asNamespace("pak"))(...)
   3. plan$install()
   4. pkgdepends::install_package_plan(plan, lib = private$library, num_workers = nw, …
   5. base::withCallingHandlers({ …
   6. pkgdepends:::handle_events(state, events)
   7. pkgdepends:::handle_event(state, i)
   8. pkgdepends:::stop_task(state, worker)
   9. pkgdepends:::stop_task_build(state, worker)
  10. base::throw(new_pkg_build_error("Failed to build source package {pkg}", …
  11. | base::signalCondition(cond)
  12. global (function (e) …
  Execution halted
  Error: Process completed with exit code 1.

@IndrajeetPatil
Copy link
Member

check-readme is failing because of this issue:

✖ Failed to build OpenMx 2.21.8

@rempsyc rempsyc merged commit 6f31369 into main Nov 5, 2023
25 of 26 checks passed
@rempsyc rempsyc deleted the kruskal-wallis branch November 5, 2023 20:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add support for kruskal.test()
2 participants