フィルターのクリア

How to draw a verical line to x-axis in a graph?

2 ビュー (過去 30 日間)
M G
M G 2011 年 11 月 2 日
Hey all,
If a = [1 2 3 4 5 6 7]; and b = [1 4 7 10 7 4 1]; and the plot it by : figure,plot(a,b), how can I draw let's say a red line vertical to the value 3 and 5 in the x-axis? So that i can see the window between 3 and 5.
Thanks so much in advance, Mehdi

採用された回答

Walter Roberson
Walter Roberson 2011 年 11 月 2 日
yL = get(gca,'YLim');
line([3 3],yL,'Color','r');
line([5 5],yL,'Color','r');
  1 件のコメント
M G
M G 2011 年 11 月 2 日
Thank you Walter :)

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

その他の回答 (0 件)

カテゴリ

Help Center および File Exchange2-D and 3-D Plots についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by