Scripting Guide > Scripting Platforms > Send Messages to a Platform > Conventions for Messages and Arguments
发布日期: 11/15/2021

Conventions for Messages and Arguments

For most messages, omitting the argument for a Boolean command enables the option. For example, all of these messages create a test for unequal variances:

oneObj << Unequal Variances;
oneObj << Unequal Variances( 1 );
oneObj << Unequal Variances( "true" );
oneObj << Unequal Variances( "yes" );
oneObj << Unequal Variances( "present" );
oneObj << Unequal Variances( "on" );

The first three approaches are recommended.

Notes:

The quoted arguments "present", "absent", "on", "off", "switch", and "flip" are supported for backwards compatibility.

When the name of the JMP option contains several options separated by a comma or slash (such as the Means/Anova option or the T Square, T2 option) you can use any one of the menu names. Or, you can use the full menu name, including the comma or slash, if the string is followed by n. For example, any of these messages create a Means/Anova test:

oneObj << Means( 1 )
oneObj << Anova( 1 )
oneObj << "Means/Anova"n( 1 )

When an option appears under a menu in JMP, the corresponding script message is the option itself without the parent menu. For example, in the Oneway red triangle menu, the Nonparametric menu has multiple options under it, including Wilcoxon Test. Simply use Wilcoxon Test as a function or message in a script:

oneObj = Oneway( Y( height ), X( age ), Wilcoxon Test( 1 ));
oneObj << Wilcoxon Test( 1 );

When a menu in JMP contains values rather than options, in the script, specify the parent menu and the value as an argument. For example, in the Oneway red triangle menu, the Set Alpha Level menu has values, such as 0.10, 0.05, 0.01, and Other. To specify 0.01 in a script, add a line like the following:

oneObj << SetAlphaLevel(0.01);
需要更多信息?有问题?从 JMP 用户社区得到解答 (community.jmp.com).