I need help to remove dips(trough) from the signals. The red circle in the image indicates the dip and yellow circles indicates contributing points. Means there’re multiple points in the dip. I tried couple of algorithms but it doesn’t help. Using find_peaks() from scipy package only helps to find the deepest point but it doesn’t help to find the other contributing points. Other algo I tried which only finds peaks and contributing points not the dips.

One potential solution can be anomaly detection. But my final analysis is anomaly detection and this dips aren’t considered as anomaly. These are just noise. So I can’t use the anomaly detection algorithms.

enter image description here enter image description here Can anyone please help me with ideas/algo to remove the whole downward spike-The deepest point + the its contributing points?


1 Answer 1


It appears that you are defining a dip as a relatively steep decline, a relatively short period of lower values, and a relatively steep increase. If that is true, you can calculate the first derivative of the data and set a threshold on the first derivative to match that pattern.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.