add more X and Y ticks (dynamically)
11 ビュー (過去 30 日間)
古いコメントを表示
Hi,
The auto tick mode for the X and Y axis works well when you zoom, pan and resize. But often I find that there are not enough ticks added to both axes. There can be large gaps between the labels, big enough to add one or two more ticks with labels.
Is there a simple way to add more X and Y ticks, while keeping the benefits of the auto mode (ticks are updated dynamically after zoom, pan and resize)?
If not, i have to write something on my own (similar to Datetickzoom), but I figured I could ask first...
Btw. if I create a plot in R2015b with the code below, then there is no tick update for the y axis at all. (with a max of 120 it works ok)
figure
xlim([0,18]);
ylim([0,150]);
0 件のコメント
回答 (1 件)
Sharmila Raghu
2017 年 1 月 5 日
Unfortunately, there is currently no way to change how many ticks are chosen in ‘auto’ mode. I work for MathWorks and I have forwarded this feedback to the appropriate product team. You may want to turn on the minor grid. The grid lines may help in gauging data between ticks, but I understand this isn’t exactly what you want.
Regarding the [0,150] limits, 50 is chosen as the tick spacing because choosing a smaller value would result in too many ticks.You could choose [0, 140] or [0,160] and the spacing would become 20 and more ticks would be drawn.
0 件のコメント
参考
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!