こんにちは、jmp スクリプトの初心者です。2012 年に作成されたスクリプトが添付されていますが、jmp16 に移行してから機能しなくなり、jmp14 で動作しました。基本的に、すべてのカラム パラメータの仕様の上限と下限を読み取ることができます。 以下は、エラー メッセージと、読み込んだデータ ファイルのサンプルです。どんな助けでも大歓迎です。私は脚本を書きませんでしたが、その人はその後会社を辞めました。
ご協力いただきありがとうございます。


Names Default to Here() で監視するものは何もありません。デフォルトのスコープを設定しているだけです。コードが大きなコードの途中にある場合は、Names Default to Here() を JSL の最初の行に移動する必要があります。それが機能しない場合は、その行を完全に削除します。また、新しい If() 句を追加して、列が数値連続列でない場合に Spec Limits を処理しないようにしました。
を取り外します
Version = JMPVersion();
そしてあなたの
Version = "Limits as Attributes, v2.1 December 24, 2012";
TXさん、ありがとう
それでも同じエラーメッセージ。追加したのは 2 行だけだと思いますが、他に変更はありませんか?
org ファイルの元の行を見逃していることに気付きました。
バージョン = "属性としての制限、v2.1 2012 年 12 月 24 日";
上記は元のファイルにありましたが、提案されたソリューションが変更されるかどうかはわかりません。
バージョンの値を見ると、確かに 16 witch が実行されています。Names Default to Here を見ようとするとハングアップしますか?
名前のデフォルトはここ (1) です。
バージョン = JMP バージョン ();
ありがとう
2つの問題がありました。
- 変数「バージョン」の値が設定されていませんでした。
- JMP 16 では、Character 変数に遭遇するとコードが停止します。
両方の問題を修正しました。Character の Data Type をチェックするのではなく、Modeling Type が Continuous であることを実際にチェックします。名義または序数の数値列にも仕様制限を設定しないでください。
Names Default To Here( 1 );
version = JMP Version();
/*** This script will save the values in the specified rows as ***/
/*** Spec Limit column attributes for each respective column. ***/
/*** If there is no value for a particular column, the Spec ***/
/*** Limit attribute for that column will not be changed. By ***/
/*** saving the limits as column attributes, the Cpk analysis ***/
/*** along with limits reference markers, will automatically ***/
/*** be generated whenever a distribution is generated for a ***/
/*** column. ***/
/*** Alternatively, this script can be used to delete the ***/
/*** Spec Limits column attributes altogether by checking the ***/
/*** "Delete Attributes" checkbox. ***/
// 10/28/2004 v2.0
// 12/24/2012 v2.1, modified to handle limits with units, like "2 Ohms"
Limits_dlg = Dialog(
Text Box( Version ),
Text Box( " " ),
Text Box( " " ),
Text Box( " " ),
Text Box( "Spec Limits:" ),
Text Box( " " ),
LineUp( 2,
"LSL is in row", LSLRow = EditNumber( 1 ),
"USL is in row", USLRow = EditNumber( 2 )
),
Text Box( " " ),
Text Box( " " ),
Text Box( " " ),
Text Box( "My table already has Spec Limits attributes, and I want to delete them... " ),
DelAttr = Check Box( "Delete Attributes", 0 ),
Text Box( " " ),
HList( Button( "OK" ), Button( "Cancel" ) )
);
If( Limits_dlg["Button"] == -1,
Throw( "!User Cancelled" )
);
If( Limits_dlg["DelAttr"] == 1,
For( i = 1, i < N Col() + 1, i++,
Column( i ) << Delete Property( "Spec Limits" )
),
//Else...
For( i = 1, i < N Col() + 1, i++,
If( As Column( i ) << get modeling type == "Continuous",
LSpec = Column( i )[Limits_dlg["LSLRow"]];
LSpec = Num( Word( 1, Char( LSpec ) ) ); //Truncate to numeric if it has units appended to it.
USpec = Column( i )[Limits_dlg["USLRow"]];
USpec = Num( Word( 1, Char( USpec ) ) ); //Truncate to numeric if it has units appended to it.
Eval(
Substitute(
Expr(
Column( i ) << Set Property(
"Spec Limits",
{LSL( _LSL ), USL( _USL ), show limits( 1 )}
)
),
Expr( _LSL ), LSpec,
Expr( _USL ), USpec
)
);
)
)
);