How can one remove axis ticks on imagesc but keep labels?
29 ビュー (過去 30 日間)
古いコメントを表示
I am trying to remove the physical tick marks from imagesc on both the x and y axes, but have labels for both axes I want to keep. Is there a way to remove the ticks, or control the size of them so they are virtually invisible?
0 件のコメント
回答 (2 件)
Mike Garrity
2016 年 3 月 3 日
Have you tried setting the length of the ticks to 0?
set(gca,'TickLength',[0 0])
2 件のコメント
Mr M.
2018 年 7 月 23 日
I have the same problem, but I do not need the axis lines, nor ticks, but I want to keep the xlabel and ylabel. How to do this?
Ruben Haverkort
2021 年 5 月 28 日
編集済み: Ruben Haverkort
2021 年 5 月 28 日
Hi Mr M.
This answer is probably a bit late for you, but maybe somebody else googling this topic might benefit.
To remove the 'axis lines', use
grid off
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!