Finding local maxima's and minima's of a curve

This mfile finds local maxima's and minima's of a curve. The bugs have been fixed in this version.
Updated 9 Apr 2013

View License

%output = fpeak(x,y,s,range)
% x and y are the data
% s: is a scallar and determines the sensitivity of the function, the
% default (minimum) value is 1.
% Range: is the interval to find local maxima and minima and is
% optional, it has four elements: [x_min x_max y_min y_max]
% output: is the xy position of local maxima's and minima's
% SEE ALSO findpeaks
% Author: Geng Jun, Dec 09, 2003
% Email:
% Editted by: Farhad VISHKAEE, 23 May, 2010
% Email:
% LinkedIn:

Cite As

Farhad VISHKAEE (2024). Finding local maxima's and minima's of a curve (, MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2012a
Compatible with any release
Platform Compatibility
Windows macOS Linux
Find more on Chemistry in Help Center and MATLAB Answers

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes