How to call m-file
이전 댓글 표시
Hello,
I have an if condition in the intro of my code , and there are three cases i want to do like this in matlab
(example )case 1 call mfile1,
case 2 call mfile2,
case3 call mfile3
thanks :)
채택된 답변
추가 답변 (1개)
Wayne King
2012년 4월 4일
How about a switch
switch test
case 'value1'
mfile1()
case 'value2'
mfile2()
otherwise
mfile3()
end
You have not specified what the condition is, e.g. numeric, string, etc.
카테고리
도움말 센터 및 File Exchange에서 Software Development에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!