The reason why performing both detrend and high pass filter?

Hello, I am newbie for fMRI analysis.
As far as I know, the low-frequency drift could be removed by using high pass filter.
However, why do we need to use the detrend method?
Are there any systematical noises for some trends?
Also, could you explain more details of detrend in terms of mathematics? I had difficulty understanding the method from the code.

I am sorry for this naive question and thank you for your answer :slight_smile:
Have a nice day.

Best regards,

Hi, Thank you for your interesting question! I am not an expert in fMRI analysis but I read this explanation in XCP Engine website:

High-pass filters can be used to remove very-low-frequency drift from an acquisition; this is a form of scanner noise. The demean/detrend option additionally removes linear and polynomial drift.

This is a hint that may help you understand the complementarity of both approaches. From what I understand there are also aliasing of physiological pulsations visible in the low frequencies. But often in fMRI, there is not one single technique which is a best for a particular process and the process itself may be debatable, depending on the purpose of your analysis:

See for exemple:

Comparison of detrending methods for optimal fMRI preprocessing
Tanabe et al. NeuroImage (2002)

Beware detrending: Optimal preprocessing pipeline for low-frequency fluctuation analysis
Woletz et al. HBM (2019)

I also found this ressource useful to understand the detrending process:


Thank you for your response!
Aha, I see. It’s helping me a lot :wink:
I will check the recommended papers.
Thank you again and have a nice day!