안녕하세요,
IF 문을 사용하여 기본 스크립트를 만들려고합니다. JMP에 CASE 문이 있으면 익숙하지 않지만 제가하려는 작업은 case 문과 비슷합니다.
1. 사용자에게 1-20 범위의 숫자 만 입력하도록 요청합니다.
2. if 문을 만들고 사용자 입력에 따라 명령을 실행합니다.
예 : 사용자 입력 : 2
* 괄호 2 안의 스크립트를 실행합니다.
이에 도움이 될 수있는 기본 튜토리얼 세트를 조언 해 주시겠습니까?
이런 식으로 시도해 볼 수 있습니다.:)
userinput = New Window( "Collect user input", <<MODAL> 20,
New Window("Error!!", Text Box(" Please input a number from 1 to 20 ONLY! ")),
if(num(number_input) == 1,
//DO SOMETHING...
num(number_input) == 2,
//DO SOMETHING...
);
);</MODAL>사용자 인터페이스를보다 직접적으로 사용할 수 있습니다. 이 코드를 시도하십시오.
nw = new window("Test",
panel box("Click the icon to run the program: ",
lineup box(ncol(2),
text box("1. Tree Map"),
button box("", << set icon("TreeMap"),
<< set function(include("treemap.jsl"))),
text box("2. Neural Net"),
button box("", << set icon("NeuralNet"),
<< set function(include("NeuralNet.jsl"))),
text box("3. Model Comparison"),
button box("", << set icon("ModelComparison"),
<< set function(include("ModelComparison.jsl"))),
text box("4. SAS Pyramid"),
button box("", << set icon("SASPyramid"),
<< set function(include("SASPyramid.jsl"))),
),
),
);
내가 있는 적절한 코드로 대체합니다. 다양한 아이콘을 얻으려면 Justin Chilton의 JMP 아이콘 내장 애드 인.