If I zoom several time graph all labels from axis X disapear (go away) and there are no visible axis X labels so it is not possible to understand the part of graph where am I.
it depends, are you manually setting the tick marks yourself ('XTick'
and 'XTickLabel'
axis properties)?
Try this simple example
plot(sin(1:10), 'o-')
without changing anything, you can zoom as much as you want, and the tick labels will always be visible
The root cause of the problem is the same as the one raised in your other question, datetick
function will manually set the tick labels, thus disabling automatic update on zoom/pan.
The good news is there are already submissions on FEX that tries to solve this exact problem with DATETICK
I run into the same problem even on the new version of MATLAB (r2014). MATLAB does not display sufficient x-axis tick labels as you zoom-in. After several experiments I found the following workaround. Following is a plot before implementing the solution. MATLAB displays only three XTick labels on the x-axis even though there is sufficient space for more (there are often even less labels as you zoom in more).
Suspecting that MATLAB thinks that it does not have sufficient space to display more labels, a workaround can be to rotate the labels. To do that, after you issue the plot commands, e.g.
plot(tsX);
hold on;
plot(tsY);
plot(tsZ);
add the following command
set(gca,'XTickLabelRotation',90);
Now MATLAB plots with more labels
I am going to report this as a bug to the MATLAB guys.