[R-meta] Meta-analysis dependency - escalc aggregate in Metafor - multiple cluster variables

Paulina Stedall P@u||n@@Sted@|| @end|ng |rom mon@@h@edu
Thu Dec 9 05:54:33 CET 2021


Hi everyone,

I'm currently working on a meta-analysis using Metafor and am seeking
assistance to address dependence in the data.

In more simple cases (e.g., one study with two patient subgroups), we have
calculated SMD and variance per subgroup, followed by aggregating these two
estimates into one combined effect size. We have taken a similar approach
for scenarios in which two studies report on outcomes for the same cohort
at two timepoints (taking into account the autocorrelation) and for studies
reporting on the same outcome using multiple measures (taking into account
the correlation between the measures). Our question relates to more complex
scenarios that involve dependence across multiple clustering variables. For
example:

The following studies assessed an outcome in two subgroups:

Study 1: assessed Y in group 1 and 2 using measure A at 11 years

Study 2: assessed Y in group 1 and 2 using measure B at 11 years

Study 3: assessed Y in group 1 and 2 using measure B at 12 years

Study 4: assessed Y in group 1 and 2 using measure B at 13 years

Study 5: assessed Y in group 1 and 2 using measure B at 14 years



This means we want to aggregate effect sizes from both groups (struct=”ID),
across 4 time points (struct=”CAR”), and from measure A and B (at time
point 1 only; struct=”CS”).



Could we do this in separate steps, by first aggregating the ES from both
groups, then measure A and B at 11 years, and then across time points? Or
should we aggregate over subgroups first and subsequently use
struct=”CS+CAR” to account for two clustering variables simultaneously? The
latter is probably preferred, but the following code results in an error.



dat <- escalc(measure="SMD", m1i=M_target, sd1i=SD_target, n1i=N_target,

                        m2i=M_control, sd2i=SD_control, n2i=N_control,
data=data)

class(dat)

dat



   Subgroup Timepoint Study Cohort Measure M_target SD_target N_target
M_control SD_control N_control      yi     vi

1         1        11     1      1       1    -0.13      0.90       57
     0.07       0.60        49 -0.2558 0.0383

2         2        11     1      1       1     0.10      0.85       53
     0.07       0.60        49  0.0402 0.0393

3         2        11     2      1       2     8.63      2.96       32
     9.36       3.02        36 -0.2412 0.0595

4         1        11     2      1       2     7.36      3.27       33
     9.36       3.02        36 -0.6294 0.0610

5         2        12     3      1       2     8.37      3.51       38
     9.96       2.79        48 -0.5038 0.0486

6         1        12     3      1       2     7.67      3.56       46
     9.96       2.79        48 -0.7120 0.0453

7         2        13     4      1       2     8.26      2.81       38
     9.94       2.76        50 -0.5987 0.0484

8         1        13     4      1       2     7.86      2.87       49
     9.94       2.76        50 -0.7332 0.0431

9         2        14     5      1       2     9.17      3.07       29
     9.94       3.05        34 -0.2486 0.0644

10        1        14     5      1       2     7.90      3.63       31
     9.94       3.05        34 -0.6037 0.0645



#step 1: aggregate subgroup 1 and 2

agg_subgroup <- aggregate(dat, cluster=Study, struct="ID")

agg_subgroup



#combined aggregation for time and measure >> doesn't work!

agg <- aggregate(agg_subgroup, cluster=Cohort, struct="CS+CAR", rho=0.6,
phi=0.8, time=Timepoint)

agg



Error in aggregate.escalc(agg_subgroup, cluster = Cohort, struct = "CS+CAR",  :

  Cannot aggregate estimates with a non-positive-definite 'V' matrix.

In addition: Warning message:

'V' appears to be not positive definite in cluster 1.


Thank you in advance.


Kind regards,


Paulina



-- 
*PAULINA STEDALL*
Doctor of Psychology (Clinical Neuropsychology) Candidate
Provisional Psychologist, MCRI Student
BPsy (Hons); Assoc MAPS
email: paulina.stedall using monash.edu

Turner Institute for Brain and Mental Health
School of Psychological Sciences
Monash University

	[[alternative HTML version deleted]]



More information about the R-sig-meta-analysis mailing list