Answer the question
In order to leave comments, you need to log in
Is there an efficient and not complicated algorithm for searching for pronounced peaks in 2D arrays without ML?
Tell me, for example, for such an array:
let arr = [
[4000.123, 0.0002250716, ],
[3999.641, 0.0002206956, ],
[3999.159, 0.0002314698, ],
[3998.677, 0.0002602464,],
//....... length 5678
[2998.195, 0.0005059349,]
[2997.712, 0.0004620409, ]
..........
]
Answer the question
In order to leave comments, you need to log in
As far as I know, there is no strict algorithm for searching for peaks in an arbitrary time series. Therefore, one should be content with empiricism.
Well, that's what I would do.
1. Fix the size of the sliding window.
2. At the first position of the window, I would look for the maximum.
3. Move the window so that it starts from the found maximum point.
4. Again, I would look for the maximum.
If the maximum on the first window remained the maximum on the second window, I would consider it a "pronounced peak". If not, repeat the procedure.
The issue of choosing the size of the sliding window is solved empirically.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question