MATLAB: How to get the minimum and maximum value of the xaxis when I zoom in on a plot

axescallbackguiguideplotzoom in

Is it possible to define a callback when I zoom in on the plot and get the minimum and maximum x values from the plot? Kindly request you to give an example.
Thanks in Advance.

Best Answer

Have you looked at the xlim() function?