JSL 添加恆定分類因子 DoE使用能源部
我想在 JSL 腳本中記錄常量分類因子,但似乎只有常量連續因子才能正確保存和加載。
雖然我可以輸入常量因子的字符串值,但當我生成 JSL 腳本時,字符串值將替換為數字。
例如,如果我分別輸入值為 99 和“a_string”的常數因子“X1”和“X2”,則生成的腳本為:
DOE(
Custom Design,
{
Add Response( Maximize, "Y", ., ., . ),
Add Factor( Constant, 99, "X1" ),
Add Factor( Constant, 1, "X2" ),
Set Random Seed( 1385290084 ),
Simulate Responses( 0 ),
Save X Matrix( 0 )
}
);即我的字符串值“a_string”已被替換為1。
附截圖。
有誰知道如何在 JSL 腳本中獲取恆定的分類因子?
自動化和腳本編寫回复:JSL 添加恆定分類因子 DoE既然您提到了 JSL,我假設您已經了解“幫助 > 腳本索引”。 搜索“doe”會提供大量信息,通常帶有示例:

當然,還有更廣泛的文檔。
但是,需要明確的是,我提供的是針對看似錯誤的解決方法。 所以請發送電子郵件至support@jmp.com並向他們指出這個線程。 這樣它就會被修復。
回复:JSL 添加恆定分類因子 DoE謝謝!
太精彩了。
您是否有我可能已經找到如何執行此操作的文檔鏈接?
回复:JSL 添加恆定分類因子 DoE這有點迂迴,但這樣做就可以了(Mac 上的 JMP 15):
NamesDefaultToHere(1);
// Make a factor table
dt =
New Table( "My Factors",
Add Rows( 2 ),
New Table Variable( "Table Type", "DOE Factor Table" ),
New Column( "X1",
Numeric,
"Continuous",
Format( "Best", 12 ),
Set Property( "Design Role", Design Role( Constant ) ),
Set Property( "Factor Changes", Easy ),
Set Values( [99, .] )
),
New Column( "X2",
Character,
"Nominal",
Set Property( "Design Role", Design Role( Constant ) ),
Set Property( "Factor Changes", Easy ),
Set Values( {"a_string_value", ""} )
)
);
// Make a DOE object
myDOE =
DOE(
Custom Design,
{
Add Response( Maximize, "Y", ., ., . ),
Set Random Seed( 1385290084 ),
Simulate Responses( 0 ),
Save X Matrix( 0 )
}
);
// Load in the factors
myDOE << loadFactors(dt);
// Delete the factors
Close(dt, noSave);