マニュアルに記載されているように、GUIデータを保存してロードします
function readImage(filename, hObject, handles)
handles.image.data = imageRGBNoEdge;
guidata(hObject,handles);
と
function createHistogram(handles)
imageRGB = handles.image.data;
どちらも直接呼び出されます
readImage(imageFile,hObject,handles);
createHistogram(handles);
ただし、2 番目の関数の handles.image は不明です。
??? Reference to non-existent field 'image'.
Error in ==> ui_histogram>createHistogram at 252
imageRGB = handles.image.data;
しかし、関数をもう一度呼び出すと、それはわかっていますか?