Matlab : 2 different cursor in a graph

3 views (last 30 days)
Sarah Guiffray
Sarah Guiffray on 13 Mar 2015
Hello,
I would like to call 2 different cursor in a same graph, is it possible ? I have 2 graph in a figure (using sublopt). And in the first graph, I have 3 different courb like this :
subplot(2,1,1)
plot(x_new, y2, 'r')
hold on
[hAx,hLine1,hLine2] = plotyy(x_new,y1,x_new,y3);
For the moment, I call only one cursor for my figure (so for my 2 graphics, the cursor is the same) like this :
dcm_obj = datacursormode(fig);
set(dcm_obj,'UpdateFcn',@cursorcallback);
My second problem : when I want to remove the cursor on my coubr, I can't, it stays on the graph.
Thank you in advance,
Best regards

Answers (0)

Categories

Find more on 2-D and 3-D Plots in Help Center and File Exchange

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!