localExtrema¶
Parameters¶
Parameter label |
I/O type |
Data type |
Mandatory parameter? |
Default value |
---|---|---|---|---|
|
input |
vector |
yes |
N/A |
|
input |
string ( |
no |
|
|
output |
vector |
N/A |
N/A |
Functionality¶
The module can process numerical input vectors and detects local extrema points.
The module returns a boolean value True
in outputVec
at all indices that correspond to a local extrema in inputVec
.
The type of extrema is either maxima (mode="max"
/mode="max-eq"
) or minima(mode="min"
/mode="min-eq"
).
If one of the two modes mode="max-eq"
or mode="min-eq"
is selected, local plateaus are also detected as maximum.
Here are some examples for all modes:
inputVec = [1,1,2,3,4,3,0,1,0]
mode = "max"
...
outputVec = [False,False,False,False,True,False,False,True,False]
inputVec = [1,1,2,3,4,3,0,1,0]
mode = "max-eq"
...
outputVec = [True,False,False,False,True,False,False,True,False]
inputVec = [10,8,1,5,2,2,5]
mode = "min"
...
outputVec = [False,False,True,False,False,False,False]
inputVec = [10,8,1,5,2,2,5]
mode = "min-eq"
...
outputVec = [False,False,True,False,True,True,False]