3dFWHMx Residuals

Hi there,

For SPM folks using 3dFWHMx and 3dClustSim, which subject residuals (that are subsequently averaged to generate the 3 ACF parameters) should be used–the first (individual) or second (group) level residuals?

If we should be using first level residuals, should individual ACF parameters be calculated by first running 3dFWHMx on all first level residual files for each subject and averaging them, and then averaging across all subjects?

Thank you for your guidance and for all the wonderful tools you build and maintain!

// Dani

Hi, Dani-

You should use the residuals from each subject for 3dFWHMx, and then you can average the ACF parameters. Note that your ACF parameter estimations across your group should be similar-- if they aren’t… then you might have an outlier or several?

There are some code snippets for averaging 3dFWHMx results from across a group and then running 3dClustSim, here:
See line 118 and following in the script: s.nimh_group_level_02_mema.tcsh
(Note that for broader application of codes from that work, you should also read the accompanying+linked paper, because some of the processing steps there carried important caveats due to the choices of the authors of the original work.)


Excellent, thank you for the quick response and for these resources!

A quick clarification–when you say “use the residuals from each subject” do you mean the residuals from the individual first level model or the group second level model? In SPM you can export the residuals for individual first level models (with one residual image per volume in the time series, I believe) as well as for group second level models (with one residual image per subject, I believe), and I want to make sure we’re using the correct residuals when calculating subject ACF parameters before averaging across subjects.

Thanks again!

Hi, Dani-

I am afraid I am not so up on the SPM lingo. We refer to processing each individual subject (= single subject analysis), and then taking those results and using them for group analysis. In this present discussion, the residual time series of the single subject processing (i.e., what would often be “errts” files output from afni_proc.py) should be entered into 3dFWHMx. If you have N subjects, you will then have N sets of ACF parameters.