FMRIPREP: appling ICA-AROMA and other regressors

Hi all,

If I want to use ICA-AROMA to denoise my data, and use tcompcor and acompcor as additional nuisance regressors, does the order in which I apply them matter? Or do I need to find a way to apply them at the same time? To ask another way, am I in danger of reintroducing noise with another regressor after applying ICA-AROMA, since I’m applying those regressors (tcompcor, acompcor) to already partially cleaned data (ICA-AROMA denoised), while the regressors (tcompcor, acompcor) were derived from the pre-denoised data.

I see in this paper it matters if the nuisance regressors are highpass filtered or not, which fmriprep covers with adding the cosine basis set as regressors. So would I have to apply fsl’s regfilt to the confound.tsv (at least the columns of interest) that is output by FMRIPREP too?

Sorry if it wasn’t clear and thanks for the help!

Just to clarify I assume you are talking about non agressively denoised outputs of FMRIPREP. Correct me if I’m wrong.

The best thing I can recommend is to fit a GLM with all additional nuisance regressors you want to use (applying it to ICA deinsed data) save the residuals and then apply band pass filtering to them. This order will ensure you will not reintroduce high frequency noise with nuisance regression.

Thank you for the response! Yes, I am talking about the non-aggressively denoised outputs of FMRIPREP. Regarding your answer, could another solution be taking the compcor/cosine basis functions confounds I’m interested in and make a pseudo nifti file and pass the pseudo nifiti file to fsl_regfilt using the melodic mixing matrix and the noiseICs to non-aggressively denoise the confounds. I will then take the residuals from the confounds, move them back to a tsv, or some array, to use the confound residuals in a GLM to regress the noise out of my non-aggressively denoised data.

psuedo code may look like the following:

# files output from FMRIPREP
img = non-aggressively-denoised_fmriprep_output.nii.gz
tsv = confound_matrix.tsv
melodic_mix = melodic_mix_fmriprep_output.tsv
noise_ics = noise_ics_fmriprep_output.csv

# put the confounds I want to use in a nifti file
tsv_nifti = tsv.to_nifti()

# non-aggressively denoise the tsv file 
fsl_regfilt -i tsv_nifti -o tsv_denoised.nii.gz -d melodic_mix -f noise_ics.content()

tsv_denoised_nifti = tsv_denoised.nii.gz

# extract the denoised confound data
tsv_denoised = tsv_denoised_nifti.to_array_or_to_tsv()

# use a GLM to regress the confounds from the img.
GLM -i img -confounds tsv_denoised -save_residual

# returns a residual nifti such that none of the information removed by ICA-AROMA is reintroduced by the fmriprep confounds that I am interested in also applying to the data

trying to use fsl_regfilt with a pseudo nifti file produces … interesting results. So I think the better bet is to just do full regression and remove any variance explained by noise_ics in the fmriprep regressors of interest (e.g. compcor, Cosine, etc). Here is notebook explaining the steps I took