PeakDetect
PeakDetect[list]
gives a binary list in which 1s correspond to peak positions in list.
PeakDetect[list,σ]
detects peaks that survive Gaussian blurring up to scale σ.
PeakDetect[list,σ,s]
detects peaks with minimum sharpness s.
PeakDetect[list,σ,s,t]
detects only peaks with values greater than t.
PeakDetect[list,σ,{s,σs},{t,σt}]
uses different scales for thresholding sharpness and value.
Details and Options
- PeakDetect finds local maxima using the given constraints.
- PeakDetect[list] automatically chooses constraints to return a set of peaks.
- Input list can be of one of the following forms:
-
{y1,y2,…} a list of values TimeSeries[…] regularly sampled time series object EventSeries[…] regularly sampled event series object - PeakDetect[list,0,0,-∞] returns all the peaks.
- PeakDetect[list,σ,s,t] is equivalent to PeakDetect[list,σ,{s,σ},{t,0}].
- PeakDetect takes a Padding option. By default, Padding->"Reflected" is used.
Examples
open allclose allScope (12)
Data (4)
Parameters (8)
By default, an automatic scale is used:
Compute peaks at different scales:
When finding peaks at scale , only peaks that sustain a blur up to scale are returned:
Signal and its blurred version at scale :
By default, peaks are not filtered based on their sharpness, equivalent to :
Specify minimum sharpness value :
Sharpness, defined by the negative second derivative, should be greater than the specified :
Specify a minimum height value :
Apply the value threshold after smoothing the data using a scale :
Options (1)
Padding (1)
By default, Padding->"Reflected" is used:
Applications (3)
Find peaks of the recent sunspot activity:
Peaks in a discrete-time Fourier transform:
Mean daily temperatures for Chicago during a period of two months:
Find peaks in the temperature:
Create a new time series with peaks stored using MetaInformation:
Text
Wolfram Research (2014), PeakDetect, Wolfram Language function, https://reference.wolfram.com/language/ref/PeakDetect.html (updated 2021).
CMS
Wolfram Language. 2014. "PeakDetect." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2021. https://reference.wolfram.com/language/ref/PeakDetect.html.
APA
Wolfram Language. (2014). PeakDetect. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/PeakDetect.html