3dNetCorr WARNING: Some null/empty ROIs in network 0/ERROR: Network [0] has at least one ROI with all null time series!

Hello AFNI Experts,

I seem to have run into a issue with my rsfMRI data analysis pipeline. I have been following afni_proc.py Example 11 (e.g. running Freesurfer on the structural images, following by SUMA and SSWarper, and then including some of the outputs for the afni_proc.py script). Then I have been using 3dresample and 3drefit to parcellate the results using the Schaefer atlas. Lastly, I use 3dNetCorr to obtain the time series from each ROI.

The issue that I have encountered is that a substantial subset of the rsfMRI sessions in the current dataset I am working with are producing the following Warning/Error message:

*+ WARNING: Some null/empty ROIs in network 0.
** ERROR: Network [0] has at least one ROI with all
null time series! If you want, you can
use '-allow_roi_zeros' option (see the help),
but it ain't necessarily recommended.

When I examine the .roidat files from the problematic participants, it appears that the ROIs that do not have non-null voxels are located in the in the inferior frontal cortices (mPFC/OFC regions) which corresponds to regions where there is low SNR. I know that signal dropout is often an issue in this region (and the mask_epi_anat images from the problematic participants reflect this) but I am wondering if there is a way to correct for this problem? Would using a different mask during rsfMRI preprocessing or the 3dNetCorr step help to alleviate this issue? I am reluctant to use the allow_roi_zeros flag without attempting to rehabilitate my data first. Any help or advice on how best to proceed would be appreciated.

Thank you,


Hello Paul-

The issue that is being warned about is that one or more ROIs in your atlas is/are filled with uniformly zero time series. This can arise from partial coverage FOV, or from having veeery low SNR in some regions, and/or from masking the data. In general, this is bad to have mathematically (the correlation with at least one all-zero time series is not well-defined), and it could create an artificial issue in your later analysis if you have a bunch of zeros that don't actually represent a flat time series, but instead an empty/null one.

More is explained in the option pointed out there that can push through this, if you want:

  -allow_roi_zeros   :by default, this program will end unhappily if any ROI
                      contains only time series that are all zeros (which
                      might occur if you applied a mask to your data that
                      is smaller than your ROI map).  This is because the
                      correlation with an all-zero time series is undefined.
                      However, if you want to allow ROIs to have all-zero
                      time series, use this option; each row and column
                      element in the Pearson and Fisher-Z transformed
                      matrices for this ROI will be 0.  NB: you cannot
                      use -part_corr when this option is used, to avoid
                      of mathematical badness.
                      See the NOTE about this option, below

So, did you apply a mask to your dataset before analysis? In general, afni_proc.py will not do so (it only estimates a mask that can be used for various tasks). Note that even if you analyze your data without any masking (so the time series in question are non-null), the fact that they have such low TSNR is something worth remembering during analysis...

--pt (another Paul)

Hi Paul,

Thanks for the prompt reply and explanation. I did not specify a mask prior to the analysis; would explicitly applying one provide me with a non-null time series in the low SNR areas? Should this be done for the afni_proc.py step and then subsequently when using 3dNetCorr, or just for the latter step?

We are testing an algorithm using real world fMRI data and signal dropout is a common enough issue, so it may be informative to include scans with the time series information, even with it's low SNR. Of course, I would interpret any results with caution given the nature of the signal in question.

Thank you once more for all your help. I truly appreciate it.


Hi, Paul-

Hmm, if the time series are nonzero everywhere (because there is no masking), I would be curious to see why this is happening, then. It might help to see an example dataset---I will ping you about that.