3dBandpass built in detrend

AFNI version info (afni -ver): AFNI_17.2.05


I am a new user trying to adapt a pre-built pipeline that includes 3dBandpass. I need to skip detrending, so I set the 'nodetrend' option to True. However, in my output it still says "180 dimensional data reduced to 179 by: detrend (1)". Is there an additional layer of detrending inherent to 3dBandpass that is not turned off by 'nodetrend'? If so, is there a way to turn it off? Please let me know if you need any additional information from me and thank you for your help!


I see that -nodetrend turns of quadratic detrending, but not the linear detrending (and the "mean" detrending is actually just the baseline estimation or 0-frequency harmonic in the bandpassing):

 -nodetrend      = Skip the quadratic detrending of the input that
                    occurs before the FFT-based bandpassing.
                   ++ You would only want to do this if the dataset
                      had been detrended already in some other program.

In practice, I don't think this should matter in temrs of degrees of freedoms, but it is likely something desirable to not have a linear trend present in most cases.

Also, I notice your AFNI version is nearly 7 (!!!) years old. I would strongly encourage you to update your code base, as there has been much work done in the meantime (fixes, updates, additions, etc.).

Secondly, if you are doing FMRI processing, it might be quite useful to look at afni_proc.py for setting up a pipeline. There are a lot of details that can be managed under the hood while still giving you a lot of flexibility to choose your desired processing features. In particular, bandpassing can be a subtle part of processing: it should not be done separately from other regression level modeling, actually, since that can lead to various inconsistencies in the outputs. Moreover, there is a lot of build in quality control (QC) features there, too. There are several examples on that webpage/help that can assist with getting started.