フィルターのクリア

denoting vertical lines with numbers

1 回表示 (過去 30 日間)
AA
AA 2017 年 11 月 23 日
回答済み: KSSV 2017 年 11 月 23 日
VLX = repmat(xy(60:60:end), 2, 1); % Vertical Line ‘x’ Locations
VLY = repmat(ylim, 24, 1)'; % Vertical Line ‘y’
% h=gcf; set(h.Children,'Xlim',[min_after_mn(f,1)-200 min_after_mn(f,1)+60]);
plot(VLX,VLY)
Hi, the above code draws vertical lines on my plot. I want to give every vertical line a number independent of the x axis. is that possible? for instance, line 1 is denoted as 1, linte 2 is denoted as 2 and so on...

採用された回答

KSSV
KSSV 2017 年 11 月 23 日
Read about text.
k = repmat(1:10,10,1) ;
%%number the line
x = ones(10,1) ; y = (1:10)' ;
plot(k)
hold on
text(x,y,num2str(y))

その他の回答 (0 件)

カテゴリ

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

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by