AFNI Command: 3dSynthesize (First Step on the Road Towards Glory)

Before we get into full-blown functional connectivity mode, we need to get acquainted with a command called 3dSynthesize. This will create a fitted time series based on selected regressors from your model, and will be used for subtracting out effects of no interest - that is, things like drift correction and motion regressors - so that the correlation we observe is protected from systematic differences in things like head motion, which can be particularly problematic in patient populations and children.

3dSynthesize requires a bucket dataset only containing coefficients from your model; therefore, you may need to go back and rerun 3dDeconvolve with the -cbucket option to make that magic happen. Once done, feed 3dSynthesize the coefficient bucket, the X matrix from 3dDeconvolve, and a selection of columns that you want for a fitted time series, e.g.:

3dSynthesize -prefix effectsNoInterest -cbucket CStats.FT+orig -matrix X.xmat.1D -select 0 1 2 3 4 5 6 7 8 9 10 11 14 15 16 17 18 19

The columns I've selected here are based on the dataset in AFNI_data6; obviously, yours will probably differ. The columns can be selected based on number, as above, or the actual label names, which can be retrieved from the X matrix with the grep command:

grep ColumnLabels X.xmat.1D

In any case, check the X matrix with either aiv or 1dplot to make sure that the columns you are extracting are indeed the effects that you want.

Hit the video for a brief demonstration, as well as a 30-second monologue to get you pumped up to use 3dSynthesize.