Message-ID: <c2743f03-508e-4e68-928f-06ec39556e96@uni-osnabrueck.de>
Date: 2023-07-22T14:52:17Z
From: Lukasz Stasielowicz
Subject: [R-meta] I2 and R2 estimation
In-Reply-To: <mailman.4814.9.1689588002.26356.r-sig-meta-analysis@r-project.org>
Hi,
For I2, there is a vignette on the official metafor page:
https://www.metafor-project.org/doku.php/tips:i2_multilevel_multivariate
For R2, you need the model with the moderator (res1) and the model
without moderators (e.g., res).
If you want to estimate R2 separately for different levels, then you can
use the tau2 values (sigma2) from the respective levels, e.g.,
(res$sigma2[1] - res1$sigma2[1]) / res$sigma2[1]
(res$sigma2[2] - res1$sigma2[2]) / res$sigma2[2]
If you prefer to estimate only one R2 value, then the following code
will suffice:
(sum(res$sigma2) - sum(res1$sigma2)) / sum(res$sigma2)
Best wishes,
--
Lukasz Stasielowicz
Osnabr?ck University
Institute for Psychology
Research methods, psychological assessment, and evaluation
Lise-Meitner-Stra?e 3
49076 Osnabr?ck (Germany)
Twitter: https://twitter.com/l_stasielowicz
On 17.07.2023 12:00, r-sig-meta-analysis-request at r-project.org wrote:
> Send R-sig-meta-analysis mailing list submissions to
> r-sig-meta-analysis at r-project.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
> https://stat.ethz.ch/mailman/listinfo/r-sig-meta-analysis
> or, via email, send a message with subject or body 'help' to
> r-sig-meta-analysis-request at r-project.org
>
> You can reach the person managing the list at
> r-sig-meta-analysis-owner at r-project.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of R-sig-meta-analysis digest..."
>
>
> Today's Topics:
>
> 1. (no subject) (#QIAO SHUYI#)
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Mon, 17 Jul 2023 08:07:11 +0000
> From: #QIAO SHUYI# <NIE22.QS at e.ntu.edu.sg>
> To: "r-sig-meta-analysis at r-project.org"
> <r-sig-meta-analysis at r-project.org>
> Subject: [R-meta] (no subject)
> Message-ID:
> <SG2PR01MB29839D0B8BA689BE67139F10F03BA at SG2PR01MB2983.apcprd01.prod.exchangelabs.com>
>
> Content-Type: text/plain; charset="utf-8"
>
> Dear All,
>
> Hi, everyone! I am currently taking the multilevel meta-analysis where effect sizes can be nested in studies. I am wondering how to get the I2 index for hetegeneity test as well as R square of the moderator analysis under rma.mv function. What are the codes to calculate those values?
>
> res1 <- rma.mv(yi = yi,
> V = vi,
> test="t",
> mod=~ mod1
> random = list(~ 1 | Study_ID, ~ 1 | Study_ID/correlation_ID),
> data = es)
> res1
>
> the fitstats function did not give R square.
>
> Thank you for your attention.
>
> Best Wishes
>
> Shuyi (Qiao)
>
>
> [[alternative HTML version deleted]]
>
>
>
> ------------------------------
>
> Subject: Digest Footer
>
> _______________________________________________
> R-sig-meta-analysis mailing list @ R-sig-meta-analysis at r-project.org
> To manage your subscription to this mailing list, go to:
> https://stat.ethz.ch/mailman/listinfo/r-sig-meta-analysis
>
>
> ------------------------------
>
> End of R-sig-meta-analysis Digest, Vol 74, Issue 18
> ***************************************************