Here's an example the warning message that appears when calling axes() within a loop.
You're using the axes() command to make a selected axes current so your plotting function plots on the selected axes. There are better ways to do that.
Don't worry about which axis is current and use axis handles in all of your plotting functions so they are applied to the correct axes. Example:
plot(handles.axes1, x, y, '-o')
Set the current figure and then set the current axes within the current figure. Do this just before you do the plotting.
set(0, 'CurrentFigure', fig)
set(fig, 'CurrentAxes', ax)
If the plotting code is lengthy and a user clicks on a different figure or axes after setting the the current axes and before the plotting is complete, the new graphics objects will be assigned to the wrong axes. This is why the first method is much better and fail-proof. The same problem occurs with the axes() solution from your question.