Thanks, Rick. I'll look into detrending as you suggest.
I have also gone a different route by mean padding the time series to appear continuous. You suggested this
here.
As a proof of concept, I want to calculate a sound>no sound contrast using the padded time series. Previously in this thread you showed me how to generate this contrast by specifying my own design matrix using -ortvec and my own -glt contrast. So I wanted to compare the two results with the understanding that the
should be identical.
1. I created indices to insert the mean time series in the proper location
1deval -expr 'bool(mod(t+1,4))' -num 240 > pad_times.1D
2. I created a mean volume and appended it to the end of the scan.
3dTstat \
-prefix dummyMean \
-datum 'short' \
pb04.scale+tlrc \
3dTcat \
-prefix 1pad.ts \
pb04.scale+tlrc \
dummMean+tlrc
3dTcat \
-prefix pb05.dummyPad \
-1pad.ts+tlrc'[1dcat pad_times.1D']
3. Then I pad the motion (and derivatives) and create a censor file to censor the mean-padded volumes. Initially I created a censor file for volumes that exceed 0.5mm FD, but lets just say that this person did not move so that I have a vector of all 0s.
1deval -expr 'bool(mod(t+1,4))' -num 240 > issues_pad.1D
1d_tool.py \
-infile MoPar.1D \
-censor_fill_parent isss_pad.1D \
-write MoPar_pad.1D
1d_tool.py \
-infile censor.1D \
-censor_fill_parent isss_pad.1D \
-write censor_pad.1D
4. Then I regress...
3dDeconvolve \
-input $runs -jobs 12 \
-polort A \
-ortvecMoPar_pad.1D demean \
-ortvec MoPar_derv_pad.1D derv \
-censor censor_pad.1D \
-num_stimts 2 \
-stim_times 1 trials.1D 'BLOCK(0.5,1)' -stim_label 1 trial \
-stim_times 2 catch_trials.1D 'BLOCK(0.5,1)' -stim_label 2 cat \
-gltsym 'SYM: trial' -glt_label 1 sound \
-overwrite -tout -bucket trial.stats \
-x1D xmat.1D -x1D_uncensored uncensor.xmat.1D
I have attached 2 images. The one that looks like the auditory cortex was created without padding the time series, but I specified the design matrix using -ortvec and you suggested earlier in this thread. The image where the whole brain is deactivated are the results of the same sound>no sound contrast, same voxelwise threshold (p<0.01) and same cluster correction (arbitrary k=50, just to clear it up) but I used the mean-padding procedure outlined above.
Do you have any recommendations? Thanks for your help!
Dustin