How to zoom in/out on an axis programmatically?

Illustration
Matt J - 2022-11-02T14:08:43+00:00
Question: How to zoom in/out on an axis programmatically?

In a figure window toolbar, there are spyglass icons that let you zoom in and out on parts of an image or plot. I'd like to know how to do this programmatically.  

Expert Answer

Profile picture of Prashant Kumar Prashant Kumar answered . 2025-11-20

hi,
There is a function "zoom" with the following options :
 
 zoom on 
 zoom off
 zoom out
 zoom reset 
 zoom xon
 zoom yon
 zoom(factor)
 zoom(fig, option) 
 h = zoom(figure_handle)

 


Not satisfied with the answer ?? ASK NOW

Get a Free Consultation or a Sample Assignment Review!