Skip to content

Commit

Permalink
Merge pull request #411 from easystats/CRAN-patch
Browse files Browse the repository at this point in the history
CRAN patch 0.6.0.1
  • Loading branch information
mattansb authored Jan 26, 2022
2 parents 3e5da37 + f6ec3c4 commit 80eefc9
Show file tree
Hide file tree
Showing 9 changed files with 57 additions and 22 deletions.
4 changes: 1 addition & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ Imports:
insight (>= 0.15.0),
parameters (>= 0.16.0),
performance (>= 0.8.0),
datawizard (>= 0.2.2.9000),
datawizard (>= 0.2.2),

This comment has been minimized.

Copy link
@IndrajeetPatil

IndrajeetPatil Jan 27, 2022

Member

BTW, the latest on CRAN is 0.2.3

stats,
utils
Suggests:
Expand Down Expand Up @@ -90,8 +90,6 @@ Suggests:
spelling,
testthat,
tidymodels
Remotes:
easystats/datawizard
VignetteBuilder:
knitr
Encoding: UTF-8
Expand Down
10 changes: 10 additions & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@ export(F_to_f)
export(F_to_f2)
export(F_to_omega2)
export(F_to_r)
export(adjust)
export(change_scale)
export(chisq_to_cohens_w)
export(chisq_to_cramers_v)
export(chisq_to_pearsons_c)
Expand Down Expand Up @@ -151,6 +153,7 @@ export(kendalls_w)
export(logoddsratio_to_d)
export(logoddsratio_to_r)
export(mad_pooled)
export(normalize)
export(odds_to_probs)
export(oddsratio)
export(oddsratio_to_d)
Expand All @@ -167,6 +170,7 @@ export(r_to_d)
export(r_to_oddsratio)
export(rank_biserial)
export(rank_epsilon_squared)
export(ranktransform)
export(rb_to_cles)
export(rb_to_common_language)
export(riskratio)
Expand All @@ -185,12 +189,18 @@ export(t_to_f)
export(t_to_f2)
export(t_to_omega2)
export(t_to_r)
export(unstandardize)
export(z_to_d)
export(z_to_r)
importFrom(bayestestR,describe_posterior)
importFrom(bayestestR,equivalence_test)
importFrom(datawizard,adjust)
importFrom(datawizard,change_scale)
importFrom(datawizard,demean)
importFrom(datawizard,normalize)
importFrom(datawizard,ranktransform)
importFrom(datawizard,standardize)
importFrom(datawizard,unstandardize)
importFrom(insight,check_if_installed)
importFrom(insight,clean_names)
importFrom(insight,find_formula)
Expand Down
6 changes: 2 additions & 4 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
# effectsize 0.6.1
# effectsize 0.6.0.1

## Breaking Changes

- `adjust()`, `normalize()`, `ranktransform()`, `unstandardize()`, and `change_scale()` are no longer re-exported from `datawizard`.
*This is a patch release.*

## Bug fixes

Expand Down
10 changes: 5 additions & 5 deletions R/effectsize.htest.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,10 @@ effectsize.htest <- function(model, type = NULL, verbose = TRUE, ...) {
dots$mu <- model$null.value

if (approx) {
if (verbose) {
warning("Unable to retrieve data from htest object. Using t_to_d() approximation.")
}

if (type == "cles") {
stop("Unable to retrieve data from htest object. Cannot compute CLES.")
} else if (verbose) {
warning("Unable to retrieve data from htest object. Using t_to_d() approximation.")
}

f <- t_to_d
Expand Down Expand Up @@ -172,14 +170,16 @@ effectsize.htest <- function(model, type = NULL, verbose = TRUE, ...) {

if (approx) {
stop("Unable to retrieve data from htest object.",
"\nTry using",ifelse(type=="cles", "'rank_biserial()'", "'cles()'")," directly.",
"\nTry using",ifelse(type=="cles", "'cles()'", "'rank_biserial()'")," directly.",
call. = FALSE
)
}

f <- switch(tolower(type),
r = ,
rb = ,
rbs = ,
r_rank_biserial = ,
rank_biserial = rank_biserial,
cles = cles
)
Expand Down
4 changes: 0 additions & 4 deletions R/equivalence_test.R
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
#' @importFrom bayestestR equivalence_test
#' @export
bayestestR::equivalence_test

#' @title Test for Practical Equivalence
#'
#' @description Perform a **Test for Practical Equivalence** for indices of
Expand Down
29 changes: 29 additions & 0 deletions R/reexports.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,33 @@
#' @importFrom bayestestR equivalence_test
#' @export
bayestestR::equivalence_test

#' @export
#' @importFrom datawizard standardize
datawizard::standardize





## TODO: removed the following from see / modelbased --------------------

#' @export
#' @importFrom datawizard ranktransform
datawizard::ranktransform

#' @export
#' @importFrom datawizard adjust
datawizard::adjust

#' @export
#' @importFrom datawizard change_scale
datawizard::change_scale

#' @export
#' @importFrom datawizard normalize
datawizard::normalize

#' @export
#' @importFrom datawizard unstandardize
datawizard::unstandardize
3 changes: 1 addition & 2 deletions cran-comments.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,5 @@ All URL issues have been resolved.

We checked 16 reverse dependencies, comparing R CMD check results across CRAN and dev versions of this package.

* We saw 1 new problems
* `report`: Error is expected. Authors have been updated and will submit updated package.
* We saw 0 new problems
* We failed to check 0 packages
9 changes: 7 additions & 2 deletions man/reexports.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions tests/testthat/test-interpret.R
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,8 @@ if (require("testthat") && require("effectsize")) {
dem60 ~ ind60 "
model <- lavaan::sem(structure, data = lavaan::PoliticalDemocracy)
int <- interpret(model)
expect_equal(int$Name, c("GFI", "AGFI", "NFI", "NNFI", "CFI", "RMSEA", "SRMR", "RFI", "IFI", "PNFI"))
expect_equal(int$Value,c(0.9666, 0.9124, 0.9749, 1.0001, 1, 0, 0.0273, 0.9529, 1.0001, 0.5199), tolerance = 0.001)
expect_equal(int$Name, c("GFI", "AGFI", "NFI", "NNFI", "CFI", "RMSEA", "SRMR", "RFI", "PNFI", "IFI"))
expect_equal(int$Value,c(0.9666, 0.9124, 0.9749, 1.0001, 1, 0, 0.0273, 0.9529, 0.5199, 1.0001), tolerance = 0.001)
})

test_that("interpret_icc", {
Expand Down

0 comments on commit 80eefc9

Please sign in to comment.