Finding the endpoint (tip) in a figure
8 views (last 30 days)
Show older comments
Hello Matlab Community,
As shown, this is a figure i generated using matlab. I want to obtain only the endpoints(in red dot) of the figure. Then use the obtain points to plot dotted points.
I tried using the findpeak function but i realized certain endpoints of the values are missing and i couldnot find the points either.
Thanking you in advance
0 Comments
Accepted Answer
Fangjun Jiang
on 27 Jan 2022
Edited: Fangjun Jiang
on 27 Jan 2022
It looks like the figure is created by using stem(). If you created the figure, won't you have the data for the "red dot" already?
x=0:0.1:2*pi;
y=sin(x);
stem(x,y,'MarkerFaceColor','red')
5 Comments
Fangjun Jiang
on 31 Jan 2022
findpeaks() is the right function to use. You may need to play with the arguments.
More Answers (0)
See Also
Categories
Find more on Annotations in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!