Hi Gang,

I have a question about nesting in 3dLME, which is a challenge I am currently facing trying to perform second-level analysis of a twin dataset in 3dLME. My dataset is composed of 134 MZ twins, 50 same sex DZ twins, 70 different sex DZ twins, and 78 subjects for whom we don’t have scans of their twins. Participants completed the MID task with three event conditions of interest (cue5, cue1, cue0), and we have the first level analysis buckets, which we computed using 3dREMLfit.

I am interested in two things.

First, I want to know whether the task “worked”, that is, if the MID contrast for cue5-cue0 shows the same pattern of significant clusters in our sample as has been shown previously in the literature, but controlling for non-independence of twins.

Second, I want to know whether differences in activation between cue5 and cue0 are related to age (quantitative covariate) and other covariates of interest.

What I am struggling with the most is goal #1, more specifically, on how to tell 3dLME to account for two levels of nesting. My thinking is: Level 1 would be each individual person (since we have repeated measures of different conditions from each person), and then Level 2 would be the twin pair (because each person may be very closely genetically related to another participant in the sample, such that the observations are nonindependent in this sense). I know that the Subj column accounts for one level, but I’m not fully sure of how to account for the second. Let me show an abbreviated example of what I currently have:

model: cond*age+sex+TwinType

raneff: ‘~1’

glts I want:

- ‘cond : 1
*cue5 -1*cue0’ [goal #1] - 'cond : 1
*cue5 -1*cue0 age : ’ [goal #2]

data:

Subj ID cond sex age TwinType InputFile

aa 001 cue0 M 27 MZ /data/stats.sub-aaTwin1_REML+tlrc’[CueZero#0_Coef]’

aa 001 cue1 M 27 MZ /data/stats.sub-aaTwin1_REML+tlrc’[CueOne#0_Coef]’

aa 001 cue5 M 27 MZ /data/stats.sub-aaTwin1_REML+tlrc’[CueFive#0_Coef]’

aa 002 cue0 M 27 MZ /data/stats.sub-aaTwin2_REML+tlrc’[CueZero#0_Coef]’

aa 002 cue1 M 27 MZ /data/stats.sub-aaTwin2_REML+tlrc’[CueOne#0_Coef]’

aa 002 cue5 M 27 MZ /data/stats.sub-aaTwin2_REML+tlrc’[CueFive#0_Coef]’

bb 003 cue0 F 24 Single /data/stats.sub-bbTwin2_REML+tlrc’[CueZero#0_Coef]’

bb 003 cue1 F 24 Single /data/stats.sub-bbTwin2_REML+tlrc’[CueOne#0_Coef]’

bb 003 cue5 F 24 Single /data/stats.sub-bbTwin2_REML+tlrc’[CueFive#0_Coef]’

cc 004 cue0 M 24 DZ_DiffSex /data/stats.sub-ccTwin1_REML+tlrc’[CueZero#0_Coef]’

cc 004 cue1 M 24 DZ_DiffSex /data/stats.sub-ccTwin1_REML+tlrc’[CueOne#0_Coef]’

cc 004 cue5 M 24 DZ_DiffSex /data/stats.sub-ccTwin1_REML+tlrc’[CueFive#0_Coef]’

cc 005 cue0 F 24 DZ_DiffSex /data/stats.sub-ccTwin2_REML+tlrc’[CueZero#0_Coef]’

cc 005 cue1 F 24 DZ_DiffSex /data/stats.sub-ccTwin2_REML+tlrc’[CueOne#0_Coef]’

cc 005 cue5 F 24 DZ_DiffSex /data/stats.sub-ccTwin2_REML+tlrc’[CueFive#0_Coef]’ \

In the Subj column, I put the twin pair id (Level 2). Then, in the ID column, I differentiate paritcipants (Level 1). Currently, it’s just generating a random intercept for twin pair right? But given the need for nesting, how do I specify the model and random effects in 3dLME?

Thank you very, very much!!