Remove certain ticks on y-axis when plotting?

1 回表示 (過去 30 日間)
cocopuffs
cocopuffs 2014 年 8 月 14 日
コメント済み: Ben11 2014 年 8 月 14 日
I have a plot that has the y axis: .5 1 1.5 2 2.5 3.5 etc... I want to remove the ticks that have .5 in them, so .5, 1.5, 2.5, and 3.5, etc. so that I am left with a y-axis of 1 2 3 4...
Thanks!

採用された回答

Ben11
Ben11 2014 年 8 月 14 日
You can set directly the XTick property as follows:
set(gca,'YTick',1:1:SomeNumber);
  2 件のコメント
cocopuffs
cocopuffs 2014 年 8 月 14 日
Awesome! Thank you
Ben11
Ben11 2014 年 8 月 14 日
great you're welcome!

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

その他の回答 (0 件)

カテゴリ

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

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by