help

help >

**RE: modeling interaction with continuous predictors**Dec 22, 2021 11:12 AM | Marius Gruber

RE: modeling interaction with continuous predictors

Hello Andrew,

first of all thanks for the toolbox and also for your help here in the forum! I am using this thread from Hamed as my questions are on the same topic.

I am currently working on a study which aims to investigate the association between structural connectivity on one side and the interaction of two continuous variables x and z on the other side. We are interested in both the main effects of x and z and the interaction effect of x*z. So, after some research here on the forum, I have created the following design matrix that includes all three effects as well as several covariates. Our sample includes more than 900 subjects (MDD patients and HCs) from 3 study sites, and I z-standardized all continuous variables. For simplicity, I present only a subset of the data:

Intercept Sex Site_2 Site_3 Group_MDD Age X Z X*Z

1 0 0 0 1 0.86 -1.86 -0.83 1.56

1 1 0 0 1 0.16 1.10 1.17 1.30

1 1 0 0 0 -0.83 2.59 -0.16 -0.42

1 0 1 0 0 1.63 -0.46 -0.29 0.13

1 1 1 0 1 1.55 -1.53 -0.17 0.26

1 1 0 1 1 -1.30 -0.13 -1.17 0.15

1 0 0 1 0 -0.99 1.02 -0.37 -0.38

Test: F-test

Contrasts:

Main effect X: [0,0,0,0,0,0,1,0,0]

Main effect Y: [0,0,0,0,0,0,0,1,0]

Interaction X*Y: [0,0,0,0,0,0,0,0,1]

I have the following questions regarding these analyses:

As I understand the above posts, I can test the interaction from X and Y with this design matrix and the contrast given above. If NBS finds a network, then the structural connectivity within that network is associated with the interaction effect of X and Y. Is this correct?

Can I reliably test the simple main effects of X and Y with this design matrix and the contrasts given above, or should I create new design matrices for this that include only the variables X or Y (without their interaction)?

To ease the interpretation of the identified networks, I would perform post-hoc t-tests, using the following contrasts:

Main effect X: [0,0,0,0,0,0,1,0,0] and [0,0,0,0,0,0,-1,0,0]

Main effect Y: [0,0,0,0,0,0,0,1,0] and [0,0,0,0,0,0,0,-1,0]

Interaction X*Y: [0,0,0,0,0,0,0,0,1] and [0,0,0,0,0,0,0,0,-1]

I would use sqrt(threshold of the F-test) as the threshold in each test.

Is it possible to test these effects using the t-tests?

Thanks for your help in advance!

Best,

Marius

first of all thanks for the toolbox and also for your help here in the forum! I am using this thread from Hamed as my questions are on the same topic.

I am currently working on a study which aims to investigate the association between structural connectivity on one side and the interaction of two continuous variables x and z on the other side. We are interested in both the main effects of x and z and the interaction effect of x*z. So, after some research here on the forum, I have created the following design matrix that includes all three effects as well as several covariates. Our sample includes more than 900 subjects (MDD patients and HCs) from 3 study sites, and I z-standardized all continuous variables. For simplicity, I present only a subset of the data:

Intercept Sex Site_2 Site_3 Group_MDD Age X Z X*Z

1 0 0 0 1 0.86 -1.86 -0.83 1.56

1 1 0 0 1 0.16 1.10 1.17 1.30

1 1 0 0 0 -0.83 2.59 -0.16 -0.42

1 0 1 0 0 1.63 -0.46 -0.29 0.13

1 1 1 0 1 1.55 -1.53 -0.17 0.26

1 1 0 1 1 -1.30 -0.13 -1.17 0.15

1 0 0 1 0 -0.99 1.02 -0.37 -0.38

Test: F-test

Contrasts:

Main effect X: [0,0,0,0,0,0,1,0,0]

Main effect Y: [0,0,0,0,0,0,0,1,0]

Interaction X*Y: [0,0,0,0,0,0,0,0,1]

I have the following questions regarding these analyses:

As I understand the above posts, I can test the interaction from X and Y with this design matrix and the contrast given above. If NBS finds a network, then the structural connectivity within that network is associated with the interaction effect of X and Y. Is this correct?

Can I reliably test the simple main effects of X and Y with this design matrix and the contrasts given above, or should I create new design matrices for this that include only the variables X or Y (without their interaction)?

To ease the interpretation of the identified networks, I would perform post-hoc t-tests, using the following contrasts:

Main effect X: [0,0,0,0,0,0,1,0,0] and [0,0,0,0,0,0,-1,0,0]

Main effect Y: [0,0,0,0,0,0,0,1,0] and [0,0,0,0,0,0,0,-1,0]

Interaction X*Y: [0,0,0,0,0,0,0,0,1] and [0,0,0,0,0,0,0,0,-1]

I would use sqrt(threshold of the F-test) as the threshold in each test.

Is it possible to test these effects using the t-tests?

Thanks for your help in advance!

Best,

Marius

## Threaded View

Title | Author | Date |
---|---|---|

Hamed Zivari |
Dec 8, 2021 | |

Selma Lugtmeijer |
Mar 10, 2022 | |

Andrew Zalesky |
Mar 11, 2022 | |

Selma Lugtmeijer |
Mar 11, 2022 | |

Andrew Zalesky |
Mar 11, 2022 | |

Marius Gruber |
Dec 22, 2021 | |

Andrew Zalesky |
Dec 22, 2021 | |

Andrew Zalesky |
Dec 8, 2021 | |