Skip to content

[R-meta] Testing interaction in rma.mv()

3 messages · Stefanou Revesz, Wolfgang Viechtbauer

#
Dear Meta Community,

My studies measure the effect of a training program to improve
teachers' self-efficacy.

We have coded for the 'length of the training sessions' (training_hr)
up until each testing occasion (time).

At the pre-testing occasion, since no training is provided, we coded 0
hrs, and for subsequent testing occasions, we coded whatever hours
reported in the studies.

The problem is that now we CAN'T use 'training_hr * time' in our
`model`. Because 'training_hr' at time0 is just '0' for all studies
(see below).

Q: Is our current coding of 'training_hr' wrong? Sh/Could we code
'training_hr' differently for such an interactive model?

Any help would be highly appreciated,
Stefanou

# Data and code
d <- read.csv("https://raw.githubusercontent.com/fpqq/w/main/f.csv")

subset(d, time == "Baseline")$training_hr
#[1] 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

model <- rma.mv(gi~training_hr*time, v_gi, random = ~1|study/obs, data = d)
1 day later
#
Dear Stefanou,

Just include training_hr and time as 'main effects', no interaction. The intercept then referes to pre-testing occasion (with 0 training hours), the coefficient for time to the average difference between the post-testing occasion versus pre-testing occasion (when 0 training hours are provided at post-testing; you could rescale the variable to make the intercept correspond to a different number of training hours), and the coefficient for training_hr indicates how this average difference changes for a one-unit increase in training_hr.

Best,
Wolfgang
#
Many thanks, Wolfgang.

Stefanou

On Fri, Mar 18, 2022 at 4:33 AM Viechtbauer, Wolfgang (SP)
<wolfgang.viechtbauer at maastrichtuniversity.nl> wrote: