laszukdawid / PyEMD

Python implementation of Empirical Mode Decompoisition (EMD) method
https://pyemd.readthedocs.io/
Apache License 2.0
867 stars 224 forks source link

Adjust end condition for emd decomposition #128

Closed kritchie closed 1 year ago

kritchie commented 1 year ago

This PR fixes the condition comparing the imfNo to the max_imf amount.

From the documentation, the method is supposed to return max_imf amount of IMFs, while currently returning that number +1.

(Either this change, or an update to the docs would be required. I will leave it to the reviewers to determine which one is more suitable for this.)

kritchie commented 1 year ago

Sorry for the noise, I just realized based on the tests that this might be expected. However I still think the documentation should be updated to be more explicit about this. I will re-open a cleaner one.