Skip to content

Commit

Permalink
Extract tau^2 from the model object where possible when using an inte…
Browse files Browse the repository at this point in the history
…gral transformation.
  • Loading branch information
wviechtb committed Nov 22, 2024
1 parent 646f295 commit 00d51a1
Show file tree
Hide file tree
Showing 130 changed files with 173 additions and 146 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: metafor
Version: 4.7-54
Date: 2024-11-21
Version: 4.7-55
Date: 2024-11-22
Title: Meta-Analysis Package for R
Authors@R: person(given = "Wolfgang", family = "Viechtbauer", role = c("aut","cre"), email = "[email protected]", comment = c(ORCID = "0000-0003-3463-4063"))
Depends: R (>= 4.0.0), methods, Matrix, metadat, numDeriv
Expand Down
2 changes: 1 addition & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# metafor 4.7-54 (2024-11-21)
# metafor 4.7-55 (2024-11-22)

- some general changes to the various `forest()` functions: argument `header` is now `TRUE` by default, the y-axis is now created with `yaxs="i"`, and the y-axis limits have been tweaked slightly in accordance

Expand Down
5 changes: 5 additions & 0 deletions R/confint.rma.uni.r
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,11 @@ confint.rma.uni <- function(object, parm, level, fixed=FALSE, random=TRUE, type,
if (missing(targs))
targs <- NULL

funlist <- lapply(list(transf.exp.int, transf.ilogit.int, transf.ztor.int, transf.exp.mode, transf.ilogit.mode, transf.ztor.mode), deparse)

if (is.null(targs) && any(sapply(funlist, identical, deparse(transf))) && inherits(x, c("rma.uni","rma.glmm")) && length(x$tau2 == 1L))
targs <- c(tau2=x$tau2)

if (missing(control))
control <- list()

Expand Down
5 changes: 5 additions & 0 deletions R/confint.rma.uni.selmodel.r
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@ confint.rma.uni.selmodel <- function(object, parm, level, fixed=FALSE, tau2, del
if (missing(targs))
targs <- NULL

funlist <- lapply(list(transf.exp.int, transf.ilogit.int, transf.ztor.int, transf.exp.mode, transf.ilogit.mode, transf.ztor.mode), deparse)

if (is.null(targs) && any(sapply(funlist, identical, deparse(transf))) && inherits(x, c("rma.uni","rma.glmm")) && length(x$tau2 == 1L))
targs <- c(tau2=x$tau2)

if (missing(control))
control <- list()

Expand Down
5 changes: 5 additions & 0 deletions R/cumul.rma.uni.r
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,11 @@ cumul.rma.uni <- function(x, order, digits, transf, targs, collapse=FALSE, progb
if (missing(targs))
targs <- NULL

funlist <- lapply(list(transf.exp.int, transf.ilogit.int, transf.ztor.int, transf.exp.mode, transf.ilogit.mode, transf.ztor.mode), deparse)

if (is.null(targs) && any(sapply(funlist, identical, deparse(transf))) && inherits(x, c("rma.uni","rma.glmm")) && length(x$tau2 == 1L))
targs <- c(tau2=x$tau2)

ddd <- list(...)

.chkdots(ddd, c("time", "decreasing"))
Expand Down
5 changes: 5 additions & 0 deletions R/hc.rma.uni.r
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ hc.rma.uni <- function(object, digits, transf, targs, control, ...) {
if (missing(targs))
targs <- NULL

funlist <- lapply(list(transf.exp.int, transf.ilogit.int, transf.ztor.int, transf.exp.mode, transf.ilogit.mode, transf.ztor.mode), deparse)

if (is.null(targs) && any(sapply(funlist, identical, deparse(transf))) && inherits(x, c("rma.uni","rma.glmm")) && length(x$tau2 == 1L))
targs <- c(tau2=x$tau2)

yi <- x$yi
vi <- x$vi
k <- length(yi)
Expand Down
5 changes: 5 additions & 0 deletions R/leave1out.rma.uni.r
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,11 @@ leave1out.rma.uni <- function(x, digits, transf, targs, progbar=FALSE, ...) {
if (missing(targs))
targs <- NULL

funlist <- lapply(list(transf.exp.int, transf.ilogit.int, transf.ztor.int, transf.exp.mode, transf.ilogit.mode, transf.ztor.mode), deparse)

if (is.null(targs) && any(sapply(funlist, identical, deparse(transf))) && inherits(x, c("rma.uni","rma.glmm")) && length(x$tau2 == 1L))
targs <- c(tau2=x$tau2)

ddd <- list(...)

.chkdots(ddd, c("time"))
Expand Down
8 changes: 5 additions & 3 deletions R/predict.rma.r
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,11 @@ level, adjust=FALSE, digits, transf, targs, vcov=FALSE, ...) {
if (missing(targs))
targs <- NULL

funlist <- lapply(list(transf.exp.int, transf.ilogit.int, transf.ztor.int, transf.exp.mode, transf.ilogit.mode, transf.ztor.mode), deparse)

if (is.null(targs) && any(sapply(funlist, identical, deparse(transf))) && inherits(x, c("rma.uni","rma.glmm")) && length(x$tau2 == 1L))
targs <- c(tau2=x$tau2)

level <- .level(level)

if (!is.logical(adjust))
Expand Down Expand Up @@ -543,9 +548,6 @@ level, adjust=FALSE, digits, transf, targs, vcov=FALSE, ...) {
### apply transformation function if one has been specified

if (is.function(transf)) {
#funlist <- lapply(list(transf.exp.int, transf.ilogit.int, transf.ztor.int, transf.exp.mode, transf.ilogit.mode, transf.ztor.mode), deparse)
#if (is.null(targs) && any(sapply(funlist, identical, deparse(transf))) && inherits(x, c("rma.uni","rma.glmm")) && length(x$tau2 == 1L))
# targs <- c(tau2=x$tau2)
if (is.null(targs)) {
pred <- sapply(pred, transf)
se <- rep(NA_real_, k.new)
Expand Down
2 changes: 1 addition & 1 deletion R/zzz.r
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
.onAttach <- function(libname, pkgname) {

ver <- "4.7-54"
ver <- "4.7-55"

loadmsg <- paste0("\nLoading the 'metafor' package (version ", ver, "). For an\nintroduction to the package please type: help(metafor)\n")

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ metafor: A Meta-Analysis Package for R
[![R build status](https://github.com/wviechtb/metafor/workflows/R-CMD-check/badge.svg)](https://github.com/wviechtb/metafor/actions)
[![Code Coverage](https://codecov.io/gh/wviechtb/metafor/branch/master/graph/badge.svg)](https://app.codecov.io/gh/wviechtb/metafor)
[![CRAN Version](https://www.r-pkg.org/badges/version/metafor)](https://cran.r-project.org/package=metafor)
[![devel Version](https://img.shields.io/badge/devel-4.7--54-brightgreen.svg)](https://www.metafor-project.org/doku.php/installation#development_version)
[![devel Version](https://img.shields.io/badge/devel-4.7--55-brightgreen.svg)](https://www.metafor-project.org/doku.php/installation#development_version)
[![Monthly Downloads](https://cranlogs.r-pkg.org/badges/metafor)](https://cranlogs.r-pkg.org/badges/metafor)
[![Total Downloads](https://cranlogs.r-pkg.org/badges/grand-total/metafor)](https://cranlogs.r-pkg.org/badges/grand-total/metafor)

Expand Down
2 changes: 1 addition & 1 deletion docs/404.html

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

2 changes: 1 addition & 1 deletion docs/ISSUE_TEMPLATE.html

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

2 changes: 1 addition & 1 deletion docs/articles/index.html

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

2 changes: 1 addition & 1 deletion docs/articles/pkgdown/diagram.html

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

2 changes: 1 addition & 1 deletion docs/authors.html

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

4 changes: 2 additions & 2 deletions docs/index.html

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

4 changes: 2 additions & 2 deletions docs/news/index.html

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

2 changes: 1 addition & 1 deletion docs/pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ pkgdown: 2.1.1.9000
pkgdown_sha: 0a18bc718640aee7160a0ebbcdef5ecaae2ac4a4
articles:
pkgdown/diagram: pkgdown/diagram.html
last_built: 2024-11-21T16:31Z
last_built: 2024-11-22T07:53Z
urls:
reference: https://wviechtb.github.io/metafor/reference
article: https://wviechtb.github.io/metafor/articles
2 changes: 1 addition & 1 deletion docs/reference/addpoly.default.html

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

2 changes: 1 addition & 1 deletion docs/reference/addpoly.html

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

2 changes: 1 addition & 1 deletion docs/reference/addpoly.predict.rma.html

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

2 changes: 1 addition & 1 deletion docs/reference/addpoly.rma.html

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

2 changes: 1 addition & 1 deletion docs/reference/aggregate.escalc.html

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

2 changes: 1 addition & 1 deletion docs/reference/anova.rma.html

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

2 changes: 1 addition & 1 deletion docs/reference/baujat.html

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

2 changes: 1 addition & 1 deletion docs/reference/bldiag.html

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

2 changes: 1 addition & 1 deletion docs/reference/blsplit.html

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

2 changes: 1 addition & 1 deletion docs/reference/blup.html

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

2 changes: 1 addition & 1 deletion docs/reference/coef.permutest.rma.uni.html

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

2 changes: 1 addition & 1 deletion docs/reference/coef.rma.html

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

2 changes: 1 addition & 1 deletion docs/reference/confint.rma.html

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

2 changes: 1 addition & 1 deletion docs/reference/contrmat.html

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

2 changes: 1 addition & 1 deletion docs/reference/conv.2x2.html

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

2 changes: 1 addition & 1 deletion docs/reference/conv.delta.html

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

2 changes: 1 addition & 1 deletion docs/reference/conv.fivenum.html

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

2 changes: 1 addition & 1 deletion docs/reference/conv.wald.html

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

Loading

0 comments on commit 00d51a1

Please sign in to comment.