[R-meta] Observed effect size using escalc
Myers, Brett
brett.myers at vanderbilt.edu
Fri Aug 11 18:58:19 CEST 2017
Michael,
Thank you for your reply. Here is the pertinent line of code from which yi is derived:
meta_escalc <- escalc(measure="SMD", n1i=n, n2i=n.1, m1i=(post_mean-pre_mean), m2i=(post_mean.1-pre_mean.1), sd1i=pre_sd, sd2i=pre_sd.1, data=newdata)
In the summary data output, yi is introduced, so I assume escalc is calculating the effect size based on our input variables. I was under the impression effect size would be calculated as:
ES = [(post_mean-pre_mean) - (post_mean.1-pre_mean.1)] / (pooled pretest sd)
However, the solution of ES by hand does not match the yi output from escalc, which leads me to wonder what the calculation actually is. Any thoughts on this?
Brett
________________________________________
From: Michael Dewey [lists at dewey.myzen.co.uk]
Sent: Friday, August 11, 2017 10:53 AM
To: Myers, Brett; r-sig-meta-analysis at r-project.org
Subject: Re: [R-meta] Observed effect size using escalc
Dear Brett
It calculates it using one of dozens of formulae depending on what sort
of input you gave it. If you show us the code you have inherited we can
probably help further. The help ?escalc does have wagon-loads of detail
about this if you want to probe further.
When you do post code please set your e-mailer to send plain text as
HTML gets mangled in transmission and can make you message unreadable.
On 11/08/2017 16:21, Myers, Brett wrote:
> Hello,
>
>
>
> I am new to the metafor package and I am trying to decipher someone else's code. I'm specifically curious about the "yi" variable associated with the escalc() function. It appears that the yi vector is an output variable that escalc() appends to the dataset. The metafor documentation says that yi is the observed effect size, and we didn't enter this as an input variable, so I'm wondering what formula escalc() uses to determine yi. Would anyone here have some insight on how yi is calculated?
>
>
>
> Thanks,
>
> Brett Myers
>
> [[alternative HTML version deleted]]
>
> _______________________________________________
> R-sig-meta-analysis mailing list
> R-sig-meta-analysis at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-meta-analysis
>
> ---
> This email has been checked for viruses by AVG.
> http://www.avg.com
>
>
--
Michael
http://www.dewey.myzen.co.uk/home.html
More information about the R-sig-meta-analysis
mailing list