special data tip in matlab
2 ビュー (過去 30 日間)
古いコメントを表示
Hello i have a figure with multiple plots i want to make a data tip line as shown bellow.
so the points of intersectionof the red line with the plots will be the location of the data tips
and such data tip say what legent the red line crossed and the X,Y values of the intersection point?
is it possible ? because if we have 40 plots the 40 colors they all look the same . such "red line" could help see the legend of the plot so we want be confused
x = 0:0.01:20;
y1 = 200*exp(-0.05*x).*sin(x);
y2 = 100*exp(-0.5*x).*sin(10*x);
figure;
hold on
plot(x,y1)
plot(x,y2)
hold off
legend('data1','data2')
0 件のコメント
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Legend についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!