Longitudinal 3dLME model setup / interpretation

I plan to use 3dlme for a longitudinal (3 time point) fMRI study and I’ve reviewed the documentation and I’ve heard about the benefits of doing this quite a bit, but I’d love to check my logic in some of the specifics of how

  1. I could model the data to assess how task activation changes across age and how a co-variate collected at time 1 may moderate this relationship
  2. how I would interpret some of the output of the F and T tests.

This is a hypothetical model so I just made up some info to give more context to the question about interpreting certain type of ttests, but more broadly I’m trying to get a better handle on what questions I could ask and how I’d interpret them, versus which questions am I not modeling or interpreting correctly (or possibly over fitting my data with only 3 time points).


3dLME -prefix 3dLME_age -jobs 28 \
	-model 'Task*age_c*constant+Task*age2*constant' \
	-qVars "age_c,age2,constant" \
	-qVarCenters "0,0,0" \
	-resid allresids \
	-ranEff '~1+age_c' \
	-SS_type 3 \
	-num_glt 2 \
	-gltLabel 1 'age.task1-2.constanthigh' -gltCode  1 'Task : 1*cond1  -1*cond2  age_c : 0 constant : 3' \
	-gltLabel 2 'age2.task1-2.constanthigh' -gltCode  2 'Task : 1*cond1  -1*cond2  age2 : constant : 3' \
	-dataTable \
	Subj Task age_c age2 constant InputFile \
	001 cond1 2        6        3            /path/subs/wave1/001/con_0001.nii \
	001 cond2 2        6        3            /path/subs/wave1/001/con_0002.nii \
	001 cond3 2        6        3            /path/subs/wave1/001/con_0003.nii \
	001 cond1 3        9        3            /path/subs/wave2/001/con_0001.nii \
	001 cond2 3        9        3            /path/subs/wave2/001/con_0002.nii \
	001 cond3 3        9        3            /path/subs/wave2/001/con_0003.nii \
	001 cond1 4        16      3            /path/subs/wave3/001/con_0001.nii \
	001 cond2 4        16      3            /path/subs/wave3/001/con_0002.nii \
	001 cond3 4        16      3            /path/subs/wave3/001/con_0003.nii \
....
180 .....

First, would it be correct that I would interpret the F test for Taskage as controlling for age2 and vis-versa Taskage2 F test as controlling for age or is it running two independent F tests?
e.g.,


model 'Task*age_c+Task*age2'

Second, if I wanted to look at a quantitative variable that occurs at wave 1 (e.g., a constant within subject value across waves) to ask the question of “does this value at time one influence the relationship between task and age on whole brain activation?”, would this be an appropriate way to think about the t test (assuming variables are centered)?


-gltLabel 1 'age.task1-2.constanthigh' -gltCode  1 'Task : 1*cond1  -1*cond2  age_c : -1 constant : 3'\

Would this be saying activation for task condition 1-2 at age centered at early age at constant variable at value 3. (I’m not clear in this interpretation, as I
m sure it coming across in how I summarized it)
and would


-gltLabel 2 'age2.task1-2.constanthigh' -gltCode  2 'Task : 1*cond1  -1*cond2  age2 : constant : 3'\

be asking similar question but at centered age squared?

Thanks in advance! I’m excited to use 3dlme to optimize the way I ask some developmental longitudinal questions, but want to make sure I’m understanding the capabilities of model set up in 3dlme in this context and not over-stretching my understanding/interpretation (which I presume I am at the moment).

-model ‘Taskage_cconstant+Taskage2constant’ \

Both age and ‘constant’ are quantitative variables? If so, it’s better to center each properly and then create a new variable for their interaction. Is ‘age2’ supposed to capture the quadratic effect of age? If so, perform centering before the squaring step.

would it be correct that I would interpret the F test for Task*age as controlling for age2

I’m not so sure that ‘controlling’ is the right word to describe the situation, but yes, the F test for Task*age is with the quadratic effect accounted for in the model.

if I wanted to look at a quantitative variable that occurs at wave 1 (e.g., a constant within subject value across waves) to ask
the question of “does this value at time one influence the relationship between task and age on whole brain activation?”, would
this be an appropriate way to think about the t test (assuming variables are centered)?

Yes, the coding -gltCode 1 ‘Task : 1cond1 -1cond2 age_c : -1 constant : 3’ seems reasonable to me.

-gltCode 2 ‘Task : 1cond1 -1cond2 age2 : constant : 3’\

This one is different from the one above and assesses the different age2 effect between the two conditions when constant is held at 3. And it would be probably better formulated as

-gltCode 2 'Task : 1cond1 -1cond2 constant : 3 age2 : '\

Thank you, Gang!

Sorry I didn’t see your reply earlier. This is really helpful.

I think part of my remaining confusion is rooted in whether when I change the value of quantitative variable in the model if I am changing my interpretation in the slope or the intercept.

For example, would it ever be appropriate to rerun the model age (or another centered quantitative variable) at different values to see the effect at “high” “average” and “low” values of that variable? Or have I conflated what we are getting with the output there? I am trying to understand under what contexts you would want to see that variable at different values and what that’s telling you (and what it’s not telling you).
For example is this ever done (assuming age centered at min age) to look at differences of effects at different values of age? Or if this changing interpretation of slope, I’m trying to understand how to appropriately change my interpretation across these three options.


-gltLabel 1 'ageearly.rew-pun' -gltCode  9 'Ant : 1*rew -1*pun age : 0' \
-gltLabel 2 'agemid.rew-pun' -gltCode  9 'Ant : 1*rew -1*pun age : 1' \
-gltLabel 3 'agemid.rew-pun' -gltCode  9 'Ant : 1*rew -1*pun age : 2' \

Two additional smaller questions:

  1. If I center my variables ahead of time, do I still need to use qvars and center again (or if not “needed” is it recommended)?
  2. I noticed when I ran additional F tests, the output gives me ChiSquare results and the results seem incredibly robust and don’t seem to be taking age into my model. In other words, they do not seem accurate. For comparison, My T tests give me the coefficient and a Z score. Would I treat the ChiSquare results as F tests where they function as both the overlay and threshold? Or have I done something incorrect here?

        -glfLabel 1 'val_age' -glfCode 1 ' Task : 1*rew & 1*pun age_c :' \
        -glfLabel 2 'val_age2' -glfCode 2 'Task : 1*rew & 1*pun age2_c :' \
        -glfLabel 3 'rew_age' -glfCode 1 ' Task : 1*rew age_c :' \
        -glfLabel 4 'pun_age2' -glfCode 2 'Task : 1*pun age2_c :' \

Thanks again!

-gltLabel 1 ‘ageearly.rew-pun’ -gltCode 9 ‘Ant : 1rew -1pun age : 0’
-gltLabel 2 ‘agemid.rew-pun’ -gltCode 9 ‘Ant : 1rew -1pun age : 1’
-gltLabel 3 ‘agemid.rew-pun’ -gltCode 9 ‘Ant : 1rew -1pun age : 2’ \

Yes, these three lines assess the difference between ‘rew’ and ‘pun’ when age is adjusted at 0, 1, and 2, respectively.

If I center my variables ahead of time, do I still need to use qvars and center again (or if not “needed” is it recommended)?

Yes for both. For centering, set it to ‘-qVarCenters 0’.

   -glfLabel 1 'val_age' -glfCode 1 ' Task : 1*rew & 1*pun age_c :' \
   -glfLabel 2 'val_age2' -glfCode 2 'Task : 1*rew & 1*pun age2_c :' \
   -glfLabel 3 'rew_age' -glfCode 1 ' Task : 1*rew age_c :' \
   -glfLabel 4 'pun_age2' -glfCode 2 'Task : 1*pun age2_c :' \

I never did something like the first two lines. So I’m not so sure if the program would behave properly.

The last two line should be the following?

   -glfLabel 3 'rew_age' -glfCode 3 ' Task : 1*rew age_c :' \
   -glfLabel 4 'pun_age2' -glfCode 4 'Task : 1*pun age2_c :' \

which might be better done through -gltCode.