필터 지우기
필터 지우기

Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

please helmp me for making a gui

조회 수: 1 (최근 30일)
Chang Jae Kim
Chang Jae Kim 2013년 7월 13일
마감: MATLAB Answer Bot 2021년 8월 20일
this is my gui coding for pushbutton.
I want that the result of command 'if' is loaded to static text.
what should I do for that?Please help me.thank you.
load('CBM_DC.mat')
p1=str2double(get(handles.depth,'String'));
p2=str2double(get(handles.perm,'String'));
p3=str2double(get(handles.thick,'String'));
p4=str2double(get(handles.rank,'String'));
p5=str2double(get(handles.content,'String'));
p6=str2double(get(handles.strength,'String'));
p7=str2double(get(handles.extent,'String'));
p8=str2double(get(handles.dip,'String'));
p9=str2double(get(handles.num,'String'));
input=[p1 p2 p3 p4 p5 p6 p7 p8 p9];
[i1,is]=removeconstantrows(input);
[i2,is]=mapminmax(i1);
result=sim(net,i2');
fprintf('%8.1f \n',result);
if result<=-1
disp('Vertical, Openhole Cavity')
elseif result<=-0.6
disp('Vertical, Topset Under-ream')
elseif result<=-0.2
disp('Horizontal, Single Lateral')
elseif result<=0.2
disp('Horizontal, Multi Lateral')
elseif result<=0.6
disp('Vertical, Casedhole(Single Stage)')
elseif result<=1
disp('Vertical, Casedhole(Multi Stage)')
end
set(handles.technique,'String',result)

답변 (1개)

Image Analyst
Image Analyst 2013년 7월 13일
if result<=-1
output ='Vertical, Openhole Cavity'
elseif result<=-0.6
output ='Vertical, Topset Under-ream'
elseif result<=-0.2
output ='Horizontal, Single Lateral'
elseif result<=0.2
output ='Horizontal, Multi Lateral'
elseif result<=0.6
output ='Vertical, Casedhole(Single Stage)'
elseif result<=1
output ='Vertical, Casedhole(Multi Stage)'
end
set(handles.yourStaticText,'String',output)
  댓글 수: 2
Chang Jae Kim
Chang Jae Kim 2013년 7월 13일
thank you for your answer.
I have also one question.
in my script, I added the section point is limited two(ex) 0.5992->0.6) as followed
fprintf('%8.1f \n',result);
I want to get the result that the above the command is applied.
please help me one more. thank you.
Image Analyst
Image Analyst 2013년 7월 13일
I don't understand what you are saying. So you have that line. What's the problem?

이 질문은 마감되었습니다.

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by