I came across an issue with the ceemdan() function parameter setting num_imfs. In the documentation, the default values of num_imfs=0 is said to correspond to a
maximal number of IMFs
. However, depending on other parameter settings (e.g. noise_strength), this is not necessarily the case. A residual with two non-edge extrema, which could be further decomposed, is possible.
Then (for N>3), not num_imfs=emd_num_imfs(N) (which seems to take floor(log2(N)) as the num_imfs-value), but the smallest integer which is not less than log2(N), thus, num_imfs=ceiling(log2(N)), appears to correspond to the maximal number of IMFs (meaning the residual has maximum one non-edge extremum). Whether floor(log2(N)) or ceiling(log2(N)) corresponds to the maximal number of IMFs depends on other parameter settings such as noise_strength. Maybe the number of non-edge extrema should be checked to decide on either floor(log2(N)) or ceiling(log2(N)) for num_imfs.
Attached I provide an example. An NDVI (Normalised Difference Vegetation Index) time series of length 340 (example_NDVI.txt). It is decomposed in R using ceemdan() (ceemdan_issue.txt). When setting a noise_strength=0.3, the default setting of num_imfs=0 results in a residual with two non-edge extrema.
I hope I am not missing anything/getting wrong and this information is of help. In case it is a bug, an edit would be appreciated.
These are my sessionInfo:
R version 3.4.4 (2018-03-15)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)
packageVersion("Rlibeemd")
[1] ‘1.4.0’
Best, Katharina
I came across an issue with the
ceemdan()function parameter settingnum_imfs. In the documentation, the default values ofnum_imfs=0is said to correspond to a. However, depending on other parameter settings (e.g.
noise_strength), this is not necessarily the case. A residual with two non-edge extrema, which could be further decomposed, is possible.Then (for N>3), not
num_imfs=emd_num_imfs(N)(which seems to takefloor(log2(N))as thenum_imfs-value), but the smallest integer which is not less than log2(N), thus,num_imfs=ceiling(log2(N)), appears to correspond to the maximal number of IMFs (meaning the residual has maximum one non-edge extremum). Whetherfloor(log2(N))orceiling(log2(N))corresponds to the maximal number of IMFs depends on other parameter settings such asnoise_strength. Maybe the number of non-edge extrema should be checked to decide on eitherfloor(log2(N))orceiling(log2(N))fornum_imfs.Attached I provide an example. An NDVI (Normalised Difference Vegetation Index) time series of length 340 (example_NDVI.txt). It is decomposed in R using
ceemdan()(ceemdan_issue.txt). When setting anoise_strength=0.3, the default setting ofnum_imfs=0results in a residual with two non-edge extrema.I hope I am not missing anything/getting wrong and this information is of help. In case it is a bug, an edit would be appreciated.
These are my sessionInfo:
R version 3.4.4 (2018-03-15)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)
Best, Katharina