help > RE: Clarification on ROI-to-ROI analysis data sources and transformations applied
Aug 28, 2025  11:08 PM | Alfonso Nieto-Castanon - Boston University
RE: Clarification on ROI-to-ROI analysis data sources and transformations applied

Hi Sarah,


The only thing amiss that I noticed in your script is the ROI extraction step (you are using 'functional_roiextract' as an additional step during preprocessing for not obvious purpose, as ROI extraction typically happens automatically during the Setup step instead, so the data files extracted in that 'functional_roiextract' step will simply go unused in the rest of the analyses).


And coming back to your original question, your description of what happens to compute connectivity values is approximately correct, a bit more precisely what happens during the Setup step is:


1. Extract voxel values from ROIs (using masks) on the unsmoothed images.


Then, what happens during the Denoising step is:


2. Denoise the resulting ROI timeseries (e.g. removes mean, outlier scans, white matter, CSF and motion covariates and band-pass filter).


And last, what happens during the First-level step is:
3. Calculate the correlation between the resulting denoised ROI time series.
4. Apply Fisher’s z-transform (arctanh).


Hope this helps 


Alfonso


 


Originally posted by samik29:



Hello,


I’m trying to perform an ROI-to-ROI analysis with CONN batch, but I can’t find a clear answer on exactly which dataset the software uses for the analysis.


For reproducibility, our lab recently switched from the default CONN preprocessing pipeline to a custom one. As a result, I now provide CONN with fully preprocessed images directly.


From what I understand, the ROI analysis should use the images specified in the secondary dataset, in my case, the unsmoothed scans.


To better understand CONN’s processing, I also tried to compute the correlation matrices outside of CONN, but my results didn’t match. Could you clarify:
- Which exact images are used for the ROI-to-ROI step (extraction of voxel's activation corresponding to voxels in the ROI mask)?
- What transformations are applied internally before correlations are computed?


Here’s what I currently believe happens during ROI-to-ROI analysis:
1. Extract voxel values from ROIs (using masks) on the unsmoothed images.
2. Compute the mean signal within each ROI.
3. Calculate the correlation between ROI time series.
4. Apply Fisher’s z-transform (arctanh).


Is there anything I’m missing? I’ve attached the script I used for reference.


Additionally, I noticed that the denoising results obtained using our pipeline differ from those produced when denoising in CONN (even when using the same parameters). Do you know why this might happen?


Is it possible to provide only the essential files, such as functional images, CSF, white matter masks, outlier files, and motion parameters (and not anatomical which will not be used as the preprocessing is aleady done), directly to the batch without triggering the segmentation step? (for testing on old projects I want to download the essential files and not the entire dataset)


Thank you in advance.


Best regards,
Sarah


 


The denoising used in our denoising pipeline:


```
wm_mask = fullfile(anat_dir, dir(fullfile(anat_dir,'wc2sub-*.nii')).name);
csf_mask = fullfile(anat_dir, dir(fullfile(anat_dir,'wc3sub-*.nii')).name);


conn_module('preprocessing',...
             'functionals',   {smoothed_imgs}, ...
             'covariates',    struct(...
                 'names',     {{'realignment','scrubbing'}},...
                 'files',     {{motion_file, outlier_file}}),...
             'masks',         struct(...
                 'White',     {{wm_mask}},...
                 'CSF',       {{csf_mask}}), ...
             'steps',         {'functional_regression', 'functional_bandpass'}, ...
             'reg_names',     {'realignment','scrubbing','White Matter','CSF'}, ...
             'reg_dimensions',[inf, inf, 5, 5], ...
             'reg_deriv',     [1, 0, 0, 0], ...
             'bp_filter',     [0.008 0.09] )
```



 

Threaded View

TitleAuthorDate
samik29 Aug 12, 2025
RE: Clarification on ROI-to-ROI analysis data sources and transformations applied
Alfonso Nieto-Castanon Aug 28, 2025