how mark the highest maximums of a graph?
5 views (last 30 days)
Victoria Pilar Quesada García on 10 Mar 2022
hello, I try to mark the highest maximums of a graph that I make using data from an excel. but I can't.
the code i use is this:
% Representación Gráfica
I get an error with the select function and I don't know what to do
Steven Lord on 10 Mar 2022
Let's plot some sample data.
x = 0:360;
y = sind(x).*(x-60).*(x-180).*(x-210)/(360.^2);
Identify the local maxima and plot a second "line" highlighting them with circles.
L = islocalmax(y);
plot(x(L), y(L), 'o')