When you first draw an image with imshow, let it return a handle to the image object it creates:
A = (the initial matrix of image data);
hImage = imshow(A);
Then, to refresh the image with new data, try the following instead of calling again imshow:
B = (modification of the original image matrix A);
set(hImage, 'CData', B);
Using the command set, you will modify the created image object (the list of properties of the image object can be found here ).
Alternatively, you can also add additional parameters to the call imshowto indicate which axis object will display the image in:
hAxes = (the handle to an axes object);
imshow(A, 'Parent', hAxes);
EDIT:
GUI , MATLAB . , , GUI: ( SO ), UserData ( SO ) setappdata/getappdata guidata. guidata , GUIDE.