A fast and easy function for detrending 3D datasets
Updated 29 Jan 2017

View License

This function behaves just like Matlab's detrend function, but detrending is applied along the third dimension of all rows and columns of a 3D dataset. If your samples are not evenly spaced in along the third dimension, you can include a corresponding time vector for the least-squares detrending.

Cite As

Chad Greene (2024). detrend3 (, MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2012b
Compatible with any release
Platform Compatibility
Windows macOS Linux
Find more on Preprocessing Data in Help Center and MATLAB Answers

Inspired by: trend

Inspired: xcorr3, EOF, detrendNaN3

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes