Get the indices of the local maxima in a list of numbers
local_maxima(x)
Vector of numbers.
A vector containing the indices of the elements that are local maxima in the given input.
# NOT RUN { local_maxima(c(1, 5, 3, 2, 4, 3)) # }
Run the code above in your browser using DataCamp Workspace