error in displaying image
8 views (last 30 days)
Show older comments
I have a code
function pbRecognize_Callback(hObject, eventdata, handles)
% hObject handle to pbRecognize (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
charvec = handles.charvec;
selected_net = get(handles.editNN,'string');
selected_net = evalin('base',selected_net);
result = sim(selected_net,charvec);
[val, num] = max(result);
set(handles.editResult, 'string',num);
i tried sing the code without using GUI BUT I GET ERROR ,UNDEFINED VARIABLE selected_net
PLEASE HELP
0 Comments
Answers (1)
Image Analyst
on 2 May 2012
Why do you have this line:
selected_net = evalin('base',selected_net);
when you've just retrieved it from the "editNN" edit text box? Where is selected_net supposed to originate? Also, I don't see where it's trying to display an image (no image(), imagesc() or imshow()). Did you modify the downloaded code in any way? Did you try to contact the author?
0 Comments
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!