やあ、
参照データ テーブルの値に基づいてテスト結果をオフセットする jmp スクリプトがあります。
そうなる:
1. データテーブルと参照データテーブルを読み込む
2. サイト番号を選択するための新しいウィンドウを生成します。
3. ユーザー入力 (サイト番号 1 または 2) に基づいて、これらのデータを参照データ テーブルの値に合わせます。
ウェーハIDで平均し、オフセットをメインデータテーブルに適用します
スクリプトは次のとおりです。期待される出力が生成されません
Names Default To Here( 1 );
dt1 = Data Table( "Reference data table" );
dt2 = Current Data Table();
For( i = 1, i <= N Rows( dt1 ), i++,
theTest = dt1:Tests[i];
Try( Column( dt2, theTest ) << set property( "TheMean", dt1:mean[i] ) );
);
New window( "", modal,
ct = checkbox({"1","2"}),
Buttonbox ("Ok",
get = ct << Get Selected ();
)
);
sitenum = Transform Each({str}, get, Num(str));
Col_List1 = dt2 << Get Column Names( "String" );
For( c = 1, c <= N Col( dt2 ) - 1, c++,
theMatrix = [];
name = Column( Col_List1[c] ) << Get name;
If( Contains( Col_List1[c], "IL" ),
mean = .;
Try( mean = Column( dt2, col_list1[c] ) << get property( "theMean" ) );
// Don't process if a value for theMean does not exist
If( Is Missing( mean ) == 0,
For Each Row(
If( Contains(sitenum, dt2:SiteNumber), // Something needs to be changed here *****
r = Row();
//mean = dt1:Mean[dt1 << Get Rows Where( :Tests == name )];
//measure = mean - Col Mean( If( dt2:Strips == dt2:Strips[r], Column( dt2, c ), . ) );
measure = mean - Col Mean( As Column( dt2, c ), :Wafer ID );
theMatrix = theMatrix || Column( dt2, c )[r] + measure;
);
);
Column( dt2, c ) << Set Values( theMatrix );
);
);
);