4.1 Calculating standardized mean differences

To calculate standardized mean differences (SMD), we need means, SDs, and sample sizes per group. In this example, we’ll be looking at the dat.normand1999 dataset included with metafor:

source n1i m1i sd1i n2i m2i sd2i
Edinburgh 155 55 47 156 75 64
Orpington-Mild 31 27 7 32 29 4
Orpington-Moderate 75 64 17 71 119 29
Orpington-Severe 18 66 20 18 137 48
Montreal-Home 8 14 8 13 18 11
Montreal-Transfer 57 19 7 52 18 4
Newcastle 34 52 45 33 41 34
Umea 110 21 16 183 31 27
Uppsala 60 30 27 52 23 20

To calculate effect sizes, we use the function metafor::escalc, which incorporates formulas to compute many different effect sizes. A detailed explanation, with references to the formulas used, can be found by selecting the function, and pressing F1.

df_smd <- escalc(measure = "SMD",
                 m1i = m1i,
                 m2i = m2i,
                 sd1i = sd1i,
                 sd2i = sd2i,
                 n1i = n1i,
                 n2i = n2i,
                 data = dat.normand1999)
df_smd
source n1i m1i sd1i n2i m2i sd2i yi vi
Edinburgh 155 55 47 156 75 64 -0.3551696 0.0130647
Orpington-Mild 31 27 7 32 29 4 -0.3479400 0.0644689
Orpington-Moderate 75 64 17 71 119 29 -2.3175692 0.0458121
Orpington-Severe 18 66 20 18 137 48 -1.8879823 0.1606177
Montreal-Home 8 14 8 13 18 11 -0.3839641 0.2054333
Montreal-Transfer 57 19 7 52 18 4 0.1721487 0.0369106
Newcastle 34 52 45 33 41 34 0.2720521 0.0602671
Umea 110 21 16 183 31 27 -0.4245963 0.0148630
Uppsala 60 30 27 52 23 20 0.2895562 0.0362717

Note that the function returns the original data, with two added columns: yi and vi. These are the SMD effect size and its variance.