列錶框和迭代你好,
我有一份顯示數據的報告,其架構如下:
H1 = H 列錶框(
V1 = V 列錶框() / V2 = V 列錶框() / V3 = V 列錶框() / V4 = V 列錶框()
);
是否需要等待使用迭代來編寫此類結構的腳本,因為所有 V 列錶框都是相同的。
我嘗試使用 H1 << append (vi) 方法,但它不起作用。
此致
萊昂內爾
回覆:列錶框和迭代它永遠不會——當你知道答案時!
關鍵是我們需要製作一個特定的腳本作為表達式或字串,然後在它們準備好時對其進行評估。 這種做法在程式設計中並不常見。
回覆:列錶框和迭代謝謝您,並對我遲到的回覆表示歉意。 看來我可以試試看:)
回覆:列錶框和迭代感謝你的回覆。看起來沒那麼複雜:)
回覆:列錶框和迭代這是獲得原始結果的方法,儘管我更喜歡吉姆的方法。
New Window( "Test",
hlb = H List Box()
);
For( b = 1, b < 5, b++,
hlb << Append(
Eval(
Parse(
Substitute(
"vlb nnn = V List Box( Text Box( \!"Here I am!\!") )",
"nnn",
Char( b )
)
)
)
)
);回覆:列錶框和迭代以下是如何透過使用 JMP 列表作為允許迭代的結構來執行我認為您想要的操作的範例
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA\Big Class.jmp" );
// iteration list
iList = {};
// Create a display window
NW = New Window( "Test", ob = Outline Box( "Results" ) );
// Create multiple V List Boxes and add them to the display window
For( i = 1, i <= 4, i++,
V = V List Box( Text Box( "V List " || Char( i ) ) );
ob << append( V );
// Place the handle for each of the V List Boxes into the list
Insert Into( iList, V );
);
// Now add to the display window by referencing the V List Box of choice
iList[2] << append( Bivariate( x( dt:Height ), y( dt:Weight ) ) );
iList[4] << append( Bivariate( x( dt:Age ), y( dt:Weight ) ) );