File Exchange

image thumbnail

Find local extrema places and values

version 1.0 (1.84 KB) by

Returns structure with local extrema (minimum, maximum) places and values.

2 Downloads

Updated

View License

Returns structure with local extrema (minimum, maximum) places and values.

Elements of output structure:
minx: min places
miny: min values
maxx: max places
maxy: max values

Example:

v=[1 3 5 5 2 -2 -2 -1 8 -10 5];
o1=extrems(v)
o2=extrems(v,'ysort')
o3=extrems(v,'strict')

Outputs:
o1 =
minx: [6 10]
miny: [-2 -10]
maxx: [3 9]
maxy: [5 8]
o2 =
minx: [10 6]
miny: [-10 -2]
maxx: [9 3]
maxy: [8 5]
o3 =
minx: 10
miny: -10
maxx: 9
maxy: 8

Comments and Ratings (0)

MATLAB Release
MATLAB 7.5 (R2007b)

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video