Histogram, change x/y-axis number jump marks

4 次查看(过去 30 天)
I'm trying to change the marks on the x and y axis. The marks in the picture is 5 for x, and 0,1 in y. Because the y-axis is 0,1 the max out-zoom makes the bars hard to read in the picture (they are 1), I need to move it to see that it goes to 1 in hight (I can't use max/min as I don't know the values (I guess I could find the max value in an matrix and then put that as max value, but there must be an easier way).
What I want is to have x axis every 1 mark , and y mark every 1 or 0,5. And I didn't find anything in the help files.

采纳的回答

Thorsten
Thorsten 2015-4-25
axis([0 40 0 1.1])
set(gca, 'XTick', 1:40);
set(gca, 'YTick', 0:0.5:1);

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Histograms 的更多信息

产品

Community Treasure Hunt

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

Start Hunting!

Translated by