[R-meta] clubSandwich: Computing covariance matrix for autoregressive effects

Farzad Keyhan |@keyh@n|h@ @end|ng |rom gm@||@com
Sat May 1 18:51:39 CEST 2021


Dear James,

Thank you for your response. I must clarify what I mean by "time" here.

In our dataset below (NEW_data), we have 3 senses of time.

(1) The column titled "time_wk" represents the time interval between each
post-test and the last treatment in each study in weeks.
(2) The column titled "time_cat" represents the categorized (1, 2, 3, 4)
version of "time_wk".
(3) The column titled "post_id"   represents the index of each post test
(1, 2, 3, 4). [note: this column doesn't necessarily match "time_cat"]

We don't have a "pre-test indicator" because the effect sizes we are
computing are obtained by obtaining the pre-post standardized mean change
for each specific time interval (e.g., pre to post 1) in each treatment
group and then subtracting pre-post standardized mean change for the
corresponding interval in the control/comparison group from that.

Indeed, the time interval between each post-test and the last treatment in
used each study is so variable across the studies that focusing on effects
at each time point seemed not very reasonable.

I hope I have described our effect sizes clearly, but basically "pre-test"
is involved in all our effect sizes. So, can we, in any way, benefit from
an "ar1" structure in ***impute_covariance_matrix()*** given our coding of
"time"?


Indeed, can we generally think of "time" in the traditional longitudinal
sense or we should use "post_id" when modeling our meta-analysis using
metafor::rma.mv()?

Sorry for the long message, please see our datset below.
Fred
---------- HERE IS OUR DATASET with 3 senses of "time":
NEW_data <- read.csv("https://raw.githubusercontent.com/ilzl/i/master/z2.csv
")

On Sat, May 1, 2021 at 8:37 AM James Pustejovsky <jepusto using gmail.com> wrote:

> Hi Fred,
>
> The matrices are NPD because you have studies where the same time-point is
> repeated across multiple rows. With the AR1 structure, this leads to
> perfect correlation between effect sizes that have the same time-point.
>
> Currently, the AR1 structure implemented in impute_covariance_matrix() is
> designed only for data structures where the dependence arises from multiple
> time points, but not also from multiple outcomes. If you (or others on the
> listserv) have ideas for other structures that can accommodate multiple
> time points and multiple outcomes, I am open to implementing them in
> clubSandwich.
>
> James
>
>
> > On Apr 30, 2021, at 8:22 PM, Farzad Keyhan <f.keyhaniha using gmail.com>
> wrote:
> >
> > Dear List Members,
> >
> > I'm trying to form an autoregressive variance-covariance matrix for my
> > studies using the clubSandwich package. But for most of my studies, the
> > resultant matrices seem to be non-positive definite as suggested by the
> > warning message. My reproducible R code is below.
> >
> > Am I missing something?
> >
> > Thank you all, Fred
> > -------------
> > library(clubSandwich)
> >
> > dat = read.csv("https://raw.githubusercontent.com/ilzl/i/master/z.csv")
> >
> > impute_covariance_matrix(vi = dat$vi, cluster = dat$studyID,
> >                              ti = dat$time, ar1 = .7)
> >
> > Warning message:
> > In check_PD(vcov_list) :
> >  The following clusters have non-positive definite covariance matrices:
> > A1
> > B1
> > B2
> > B3
> > B4
> > B6
> > D1
> > D2
> > D3
> >
> >    [[alternative HTML version deleted]]
> >
> > _______________________________________________
> > R-sig-meta-analysis mailing list
> > R-sig-meta-analysis using r-project.org
> > https://stat.ethz.ch/mailman/listinfo/r-sig-meta-analysis
>

	[[alternative HTML version deleted]]



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