大家好!
我想使用JSL在决策树中获取默认的“最小大小分割”。
谢谢!

在取消选中首选项中的最小尺寸拆分(<<关)时,内部似乎是选项中显示的默认值为5。如果设置了用户的分区平台首选项,则设置值将用于您显示的提示窗口和应用程序,除非它已更改。
如果您不想要用户的首选项,请指定分区(Y(),X(),忽略平台首选项(1));
如果忽略平台首选项,则需要修改下面的脚本并假设默认最小大小为5。
这是一个脚本,用于捕获用户是否从首选项UI或分区UI设置首选项。
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Iris.jmp" );
obj = Partition(
Y( :Species ),
X( :Sepal length, :Sepal width, :Petal length, :Petal width ),
Informative Missing( 1 ),
Minimum Size Split(3)
);
obj << split best(2);<BR /><BR />//since you are letting the user do this, grab the window and get the script
scrp = (obj << get script); //if the minimum split size was set, can parse it from the script.
for(i=1, i<=narg(scrp), i++,
_tt = Arg(scrp, i);
if(Head Name(_tt) == "Minimum Size Split",
_sz = Arg(_tt,1);
Break();
)
);
_ppsz= Arg(Arg(get platform preferences(Partition(Minimum Size Split)), 1), 1);
if(Arg(_ppsz,1) == 0 & Is Missing(_sz), _sz=5,
Arg(_ppsz,1) >0 & Is Missing(_sz), _sz=Arg(_ppsz,1)
);
show(_sz);