3dNetCorr Error message

Dear AFNI experts,

This is my first time using 3dNetCorr. I got an error message but I am not sure how to fix my code. Any help would be much appreciated.

  1. I want to calculate seed-to-whole brain correlation matrix for resting state data. This is the code that I wrote for one subject:

3dNetCorr                                                           \
      -inset $subj_dir/errts.${subj}.tproject+tlrc     \
      -in_rois ROI/caudate333+tlrc                       \
      -fish_z                                                          \
      -ts_wb_corr                                                  \
      -prefix CORR/${subj}_corr

The error message that I got is:


Data sets of `-inset' and `in_rois' have different numbers of voxels per brik!

  1. Also eventually I am hoping to get the correlation matrix for each one of four ROIs (the code that I attached here is just for 1 ROI of course), but how do I integrate more than 1 ROIs into my code? The help function says

-in_rois INROIS  :(req) can input a set of ROIs, each labelled with distinct integers. Multiple subbricks can be input, each will be treated as a separate network.

but how do I do this exactly?

Thank you very much in advance!
Jiaxu

Hi, Jiaxu-

OK, just to check, what is the output of “afni -ver”?

  1. Re. the datasets, I suspect the grids of the “inset” and “in_rois” dsets might not match. What is the output of:

3dinfo -same_all_grid $subj_dir/errts.${subj}.tproject+tlrc ROI/caudate333+tlrc

  1. Your in_rois dset can be a “map” of ROIs (in fact, often is), where each ROI is defined as the set of voxels that contain a particular integer value. Then you can get both the correlation matrix of the average time series within each ROI (default behavior), and then also the wholebrain correlation map of each ROI’s average time series (using " -ts_wb_corr", as you are).

–pt

Hello pt,

Thank you so much for your reply! I think I figured it out, you were right - the grids between my ROI and preprocessed image did not match, and once I fixed that the code works now!

Thank you!
Jiaxu