Statistical Methods
Measure Peak Prominence Above a Surrounding Contour
Define the task
Peak prominence answers how far a local maximum rises above its surrounding contour, not how high it is above zero. Use it to audit a signal feature after documenting units, sampling, preprocessing and the meaning of a peak. The accompanying tool accepts one strict interior maximum and evaluates the full observed sequence. It rejects plateaus and boundary peaks deliberately; it is not a general peak detector or a clinical event classifier.
Carry out the check
Extend a horizontal line from the peak in each direction until the record ends or a strictly higher value is encountered. Equal-height peaks do not stop this search. Find the lowest value within each side's interval and choose the higher of the two minima as the contour. Subtract that contour from the peak height. Record whether a restricted window was used in other software: a local window can yield a different, smaller prominence. Missing or nonfinite samples are not silently interpolated.
Worked hypothetical example
For hypothetical sequence (0,3,1,4,0), the peak at zero-based index 1 has left minimum 0 and right minimum 1 before the higher peak, giving prominence 3−1=2. Its absolute height is three. Adding ten to every value preserves prominence, while multiplying every value by two doubles it. Keep the raw index and sample interval when translating the location to time. These calculations describe shape and do not establish that a feature is biologically meaningful.
Method checked 21 November 2026 against Primary method documentation: peak_prominences.