Skip to contents

Method for finding Extreme Points

Usage

find_extrema(signal, include_endpoints = TRUE)

Arguments

signal

Signal values (Numeric | vector)

include_endpoints

whether to include end points or not (Boolean)

Value

Indexes of all extrema values (including starting and ending points)

Details

A local extrema is the point at which a maximum or minimum value of the function in some open interval containing the point is obtained.

Author

Shubhra Prakash, shubhraprakash279@gmail.com

Examples

signal=c( 0.841471 ,0.9092974,0.14112,-0.7568025,-0.9589243)
find_extrema(signal)
#> [1] 1 2 5