你好
請求有關編寫“輸出”列腳本的協助。
我有一個分配給不同事件的 Sr ID 列表,並且需要結果輸出列,其中 LAB T0 事件與特定事件匹配

將有義務提供協助。我已附上上述螢幕截圖的 Excel 文件。
謝謝
S
給定一個看起來像這樣的數據表

JMP 在通過創建所需輸出的步驟時以交互方式提供了以下腳本
// Clear row selection
Data Table( "Example File" ) << Clear Select;
// Data table summary
// → Data Table( "Subset of Untitled 9 By (Sr ID, Event)" )
Data Table( "Example File" ) << Summary(
Group( :Sr ID, :Event ),
Freq( "None" ),
Weight( "None" ),
Link to original data table( 0 )
);
// Select matching cells
Data Table( "Example File By (Sr ID, Event)" ) <<
Select Where( :Event == "LAB_T0" );
// Delete selected rows
Data Table( "Example File By (Sr ID, Event)" ) <<
Select Where( :Event == "LAB_T0" ) << Delete Rows;
// Delete column: N Rows
Data Table( "Example File By (Sr ID, Event)" ) << Delete Columns( :N Rows );
// Change column name: Event → Output
Data Table( "Example File By (Sr ID, Event)" ):Event << Set Name( "Output" );
// Update data tables
Data Table( "Example File" ) << Update(
With( Data Table( "Example File By (Sr ID, Event)" ) ),
Match Columns( :Sr ID = :Sr ID )
);
