Using fmriprep proccessed data for PLS analyses

Does anyone have thoughts about using data that has been preprocessed with fMRIPREP (with ICA Aroma, field map free distortion correction, or other typical options) in Partial Least Squares (PLS) analyses?

Is that appropriate? On the one hand, I’ve read that the data is preprocessed like for any other analyses. On the other hand, I’ve heard about temporal filtering (I think?) and smoothing parameters needing to be particular. This needs to be confirmed (as well as the other steps).

FMRIPREP does not perform any smoothing and (with exception of the _variant-smoothAROMAnonaggr_preproc.nii.gz) does not perform any temporal filtering. You can use the _confounds.tsv output to construct a temporal denoising strategy most appropriate for your analysis.

1 Like

That’s great! Thank you. Another reason to love fmriprep.

1 Like

Reviving this topic here: we are new to fMRIprep and will also be running PLS on task based data.

Does it matter whether the confounds are regressed from native space, or after transformation to standard space? For example, at the individual level:

a) run fMRIprep → regress desired confounds from the native space output (using fslglm) → transform using ANTS → smooth with fsl → run PLS

b) run fMRIprep → regress desired confounds from the standard space output (using fslglm) → smooth with fsl → run PLS

From what I can tell, the confounds are calculated from the native space, so I would be inclined to apply them in native space? Please feel free to point out any flaws in this logic.

Hi @imolax and welcome to neurostars!

No, this does not matter, the confounds are relevant for any space. However…

You should not run additional transforms after fMRIPrep, as you want to minimize the amount of times you interpolate data. fRMIPrep is nice in that any resampling is done in a single shot. So if you want to work with standard space data, use the fMRIPrep outputs directly instead of going native → standard after the fact.

Best,
Steven

1 Like

Thank you for the rapid response, Steven! This is exactly what we needed.

Hi @Steven, I am a collaborator of Imola’s and wanted to ask you a few follow-up questions related to the confound regression step and PLS analyses.

Just to give you some background, we have decided to try to first regress out the 6 motion parameters (trans x,y,z rot x,y,z) and then complete a 5mm smooth. (ignore format)


for reg in trans_x trans_y trans_z rot_x rot_y rot_z ; do
    awk -v col=$reg 'NR==1{for(i=1;i<=NF;i++){if($i==col){c=i;break}} print $c} NR>1{print $c}' sub-005_ses-01_task-NAME_desc-confounds_timeseries.tsv > ${reg}_all_tmp.txt;
    sed '1d' ${reg}_all_tmp.txt > ${reg}_noHead_tmp.txt
    sed '1!d' ${reg}_all_tmp.txt > ${reg}_Head_tmp.txt
done

  paste *_noHead_tmp.txt >> desired_confounds_sub-XXX_ses-XX_TASKNAME_6mot.txt

  sed -i 's|n\/a|1|g' desired_confounds_sub-XXX_ses-XX_TASKNAME_6mot.txt

Text2Vest desired_confounds_sub-XXX_ses-XX_TASKNAME_6mot.txt confound_design_sub-XXX_ses-XX_TASKNAME__6mot.mat 

fsl_glm -i sub-XXX_ses-XX_TASKNAME_space-MNI152NLin2009cAsym_desc-preproc_bold.nii.gz -d confound_design_sub-XXX_ses-XX_TASKNAME_6mot.mat --out_res=sub-XXX_ses-XX_TASKNAME_space-MNI152NLin2009cAsym_desc-preproc_noconfounds_bold_6mot.nii.gz

And then we smooth (ignore below format)


fslmaths sub-${i}_ses-01_task-NAME_space-MNI152NLin2009cAsym_desc-preproc_noconfounds_bold.nii.gz -s 2.12 sub-${i}_ses-01_task-NAME_space-MNI152NLin2009cAsym_desc-preproc_noconfounds_smooth_bold.nii.gz

After that, we went into getting the datamat files ready for PLS.

We set the brain_region to 0.15 but have also tried using a personalized brain mask for each participant (just choosing the same task for each participant and using the generated brain mask from fMRIprep).

When we run batch_plsgui with our analysis txt file, we get the error:


ERROR: no common coords among datamats!
Output argument "num_behav_subj" (and possibly others) not assigned a value in the execution with
"fmri_pls_analysis>concat_st_datamat" function.

Error in fmri_pls_analysis (line 156)
		concat_st_datamat(behavdata, singleanalysis, ...

Error in batch_pls_analysis (line 543)
      fmri_pls_analysis(PLSoptions.profiles, PLSoptions.ContrastFile, ...

Error in batch_plsgui (line 41)
         batch_pls_analysis(fid)

We have figured out that we can run the PLS without regressing out the confounds, but once we do any confound regression, no common coordinates are found.

Any help would be appreciated! Thank you.
Kristina

Hi @KristinaMS and welcome to neurostars!

Sorry, I do not know what an analysis txt file is in this context.

Although it is likely not a big deal, a more common technique is to replace n/a values with the column average, not 1.

Best,
Steven