フィルターのクリア

text with arrow pointer

15 ビュー (過去 30 日間)
Tasneem Abed
Tasneem Abed 2023 年 7 月 25 日
コメント済み: Cris LaPierre 2023 年 7 月 25 日
i need help with
how to draw an arrow to point in a specific direction

回答 (1 件)

Cris LaPierre
Cris LaPierre 2023 年 7 月 25 日
  5 件のコメント
Walter Roberson
Walter Roberson 2023 年 7 月 25 日
Be careful, the positions for annotation() can only be absolute coordinates or coordinates normalized to the figure. There is no way to specify data units.
There are File Exchange contributions to make it easier to use data units
Cris LaPierre
Cris LaPierre 2023 年 7 月 25 日
Here's an example of one such program on the File Exchange
% add an annotation pointing to the 5th data point
x = 0:24;
y = randi(6000,size(x));
plot(x,y)
S = sprintf("A2="+y(5));
xa = [-1 0]+x(5);
ya = [-1000 0]+y(5);
[xaf,yaf] = ds2nfu(xa,ya);
annotation('textarrow', xaf, yaf,'String',S)

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeAnnotations についてさらに検索

タグ

製品

Community Treasure Hunt

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

Start Hunting!

Translated by