How can I zoom out past the default axis limits?
Show older comments
I just installed Matlab 2016b and have the following problem: I can't zoom out past the default axes in either direction, using the + magnifier button in a figure. I can zoom in just fine, but not out. In other words, I can't make all the data take up a tiny fraction of the plot area. Zooming past the default axes has shown hidden data on previous Matlab versions, so I would like to be able to do that still. A simple plot shows the problem:
figure;
plot([0 1], [0 1]);
Thank You
1 Comment
Kevin Short
on 8 Jan 2024
This problem seems to have reappeared in Matlab 2023b. The workaround still works (where the panning "hand" is used first, then the zoom can be extended beyond the bounds), but it is very frustrating to have this problem reappear.
Answers (3)
the cyclist
on 13 Jan 2017
I don't recall it being the case that you could zoom out beyond the original axes size, actually.
You could always do it programatically, e.g. by
xlim([-10 10])
ylim([-10 10])
4 Comments
Paul Quinn
on 13 Jan 2017
Nate Iamaio
on 12 Oct 2017
I am having the same problem with 2016b. Unfortunately to save disk space i uninstalled 2016a which didn't have this problem. Any solutions yet?
Mike
on 8 Jan 2018
I find this change rather disappointing. It seems I will now have to use xlim & ylim frequently when I used to just lasso the region of interest. Please TMW, reinstate the ability to zoom beyond the original settings.
Paul Quinn
on 8 Jan 2018
Mark Elwell
on 29 Jul 2019
0 votes
Yes, I also quickly noticed this very annoying change in the zoom functionality. Matlab basically screwed up. I don't use the newer versions so hopefully this mistake was removed afer 2016b.
1 Comment
Paul Quinn
on 29 Jul 2019
Mark Elwell
on 5 Aug 2019
0 votes
I accidentally discovered the solution. It only involves an extra mouse click or two:
- plot as usual
- click the drag icon; then quickly drag the (inner) plot; the amount doesn't matter, it just has to move
- NOW, the zoom will work as it did in days of old ... you can zoom out as much as you want, just like before
- If you double-click the plot to reset the view back to the original, you then lose the new zoom capability, meaning you have to go back to step (2) ! (this is the case for 2016b)
4 Comments
Paul Quinn
on 5 Aug 2019
Olivier Sauter
on 28 Jun 2020
Edited: Olivier Sauter
on 28 Jun 2020
Thanks, it must be a bug in the zoom since once you drag it is fine... May be reporting as bug report will lead to better behavior in next releases...
Paul Quinn
on 30 Jun 2020
Edited: Paul Quinn
on 30 Jun 2020
Paul Quinn
on 3 Jul 2020
Categories
Find more on Data Exploration in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!