3dlme model failed

Hello,

I was trying to use 3dlme to analyze our longitudinal data but the model failed to run. In brief, we have one within-subject variable (ScanPoint, 6 levels with missing data), one within-subject nuisance variable (Scanner, 14 levels with missing data), and one between-subject variable of interest (Group, 3 levels). We are interested in the main effects of Group and ScanPoint. I would like to model random intercept for each subject and random slopes for ScanPoint and Scanner. Here is part of my code:

3dLME -prefix compare_volume.nii
-jobs 10
-model “GroupScanPoint+Sex+Age+TIV"
-qVars “Age,TIV”
-ranEff “~1+Scanner ~1+ScanPoint”
-SS_type 3
-num_glt 3
-gltLabel 1 “Conv+Nonconv>Controls” -gltCode 1 "Group : 1
conv +1nonconv -1control”
-gltLabel 2 “Conv>Nonconv+Controls” -gltCode 2 "Group : 1conv -1nonconv -1control"
-gltLabel 3 “Conv>Nonconv” -gltCode 3 "Group : 1
conv -1nonconv"
-num_glf 2
-glfLabel 1 ‘StartPoint_maineffect’ -glfCode 1 'Group : 1
conv -1nonconv & 1conv -1control ScanPoint : 1p1’
-glfLabel 2 ‘EndPoint_maineffect’ -glfCode 2 ‘Group : 1conv -1nonconv & 1conv -1control ScanPoint : 1*p6’
-dataTable
Subj Group Sex Age TIV Scanner ScanPoint InputFile
sub1 nonconv 2 19 1515.41000000000 s1 p1 smwp101_S0301_00_T1.nii
sub1 nonconv 2 19 1515.41000000000 s1 p5 smwp101_S0301_08_T1.nii
sub1 nonconv 2 19 1515.41000000000 s2 p6 smwp101_S0301_OSA1_T1.nii
sub2 control 1 13 1530.95000000000 s1 p1 smwp101_S0310_00_T1.nii
sub2 control 1 13 1530.95000000000 s1 p2 smwp101_S0310_02_T1.nii
sub2 control 1 13 1530.95000000000 s1 p3 smwp101_S0310_04_T1.nii
sub2 control 1 13 1530.95000000000 s1 p4 smwp101_S0310_06_T1.nii
sub2 control 1 13 1530.95000000000 s1 p5 smwp101_S0310_08_T1.nii
sub3 conv 2 16 1486.07000000000 s2 p1 smwp101_S0333_00_T1.nii
sub3 conv 2 16 1486.07000000000 s2 p2 smwp101_S0333_02_T1.nii
sub3 conv 2 16 1486.07000000000 s2 p3 smwp101_S0333_04_T1.nii
sub3 conv 2 16 1486.07000000000 s2 p4 smwp101_S0333_06_T1.nii

When the code was running, it stuck at here with no response:

“If the program hangs here for more than, for example, half an hour,
kill the process because the model specification or the GLT coding
is likely inappropriate.”

I am wondering if this is because something is wrong with my code? If so, how can I change it?

Thank you!

Best,
Hengyi

Hengyi,

The random-effects specification

-ranEff “~1+Scanner ~1+ScanPoint” \

should be just a random slope in your case with a within-subject factor:

-ranEff “~1” \

Also do you mean to add ‘Scanner’ as an explanatory variable?

-model “Group*ScanPoint+Sex+Age+TIV+Scanner” \

Hi Gang,

Thank you for the reply! I changed the random-effect specification to “~1” and it worked this time. However, I am not sure if this is the same model I was planing to use for this data. Does “~1” only model a random intercept or model a random slope as well? Essentially I want something like ( 1 + ScanPoint | Subject) + ( 1 + ScanPoint | Scanner), so each subject and scanner have a random slope and a random intercept.

Regarding Scanner, this is a bit tricky here since Scanner is both a within-subject variable and between-subject variable in this dataset. This is multi-site longitudinal data so each site has its own scanner(s). For some sites more than one scanner was used (in which case different ScanPoints were scanned with different Scanners). Now my model looks something like

-model “Group*ScanPoint+Sex+Age+TIV+Scanner”
-ranEff “~1” \

Do you think this is the right model to use?

Thank you!

Best,
Hengyi

Essentially I want something like ( 1 + ScanPoint | Subject) + ( 1 + ScanPoint | Scanner),
so each subject and scanner have a random slope and a random intercept.

How many scanners (sites) are involved?

There are 9 sites and 14 scanners in total.

I have attempted to delay this, but now it seems to have reached a point where I have to take action and write a separate LME program that could adapt to more modeling capability. Give me a few days, and see if I can deliver a baby brother of 3dLME…

Thank you, Gang!

A new program 3dLMr has been created to deal with more flexible LME specifications, and will be available in the next AFNI release.