cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Submit your abstract to the call for content for Discovery Summit Americas by April 23. Selected abstracts will be presented at Discovery Summit, Oct. 21- 24.
Discovery is online this week, April 16 and 18. Join us for these exciting interactive sessions.
%3CLINGO-SUB%20id%3D%22lingo-sub-480402%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%E6%9B%B4%E6%94%B9%E5%88%97%20USL%20%E5%92%8C%20LSL%20%E5%B1%AC%E6%80%A7%E7%9A%84%20JMP%20%E8%85%B3%E6%9C%AC%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-480402%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%3CP%3E%E6%88%91%E6%9C%89%E4%B8%80%E5%80%8B%20JMP%20%E8%85%B3%E6%9C%AC%E5%87%BD%E6%95%B8%EF%BC%8C%E5%AE%83%E5%BE%9E%E5%84%B2%E5%AD%98%E5%9C%A8%E3%80%8CNtwk%20Osnr%20Spec%20Table%20Filename%E3%80%8D%E8%AE%8A%E6%95%B8%E4%B8%AD%E7%9A%84%E6%96%87%E5%AD%97%E6%AA%94%E6%A1%88%E5%8F%96%E5%BE%97%E4%B8%80%E7%B5%84%E8%A6%8F%E6%A0%BC%E9%99%90%E5%88%B6%E3%80%82%20%E6%88%91%E6%AD%A3%E5%9C%A8%E5%98%97%E8%A9%A6%E6%9B%B4%E6%94%B9%E2%80%9CNtwk%20Osnr%20%E8%B3%87%E6%96%99%E8%A1%A8%E2%80%9D%E8%B3%87%E6%96%99%E8%A1%A8%E4%B8%AD%E2%80%9CPctDiff_ModBer_q_calcBer%E2%80%9D%E5%88%97%E7%9A%84%20USL%20%E5%92%8C%20LSL%20%E5%88%97%E5%B1%AC%E6%80%A7%E3%80%82%20%E4%BD%86%E6%98%AF%EF%BC%8C%E7%95%B6%E6%88%91%E5%9F%B7%E8%A1%8C%E4%BB%A5%E4%B8%8B%20JMP%20%E8%85%B3%E6%9C%AC%E5%91%BD%E4%BB%A4%E6%99%82%EF%BC%8C%E6%88%91%E6%B2%92%E6%9C%89%E6%94%B6%E5%88%B0%E8%85%B3%E6%9C%AC%E9%8C%AF%E8%AA%A4%EF%BC%8C%E4%BD%86%20USL%20%E5%92%8C%20LSL%20%E5%88%97%E5%B1%AC%E6%80%A7%E6%9C%AA%E6%9B%B4%E6%96%B0%E3%80%82%20%E5%BE%9E%E8%A6%8F%E6%A0%BC%E9%99%90%E5%80%BC%E7%8D%B2%E5%BE%97%E7%9A%84%E8%A6%8F%E6%A0%BC%E9%99%90%E5%80%BC%E7%82%BA%201.7%E3%80%82%20%E7%95%B6%E6%88%91%E5%9F%B7%E8%A1%8C%E4%BB%A5%E4%B8%8B%E5%B9%BE%E8%A1%8C%E6%99%82%EF%BC%8CSpeclimit%20%E8%AE%8A%E6%95%B8%E4%B8%AD%E7%9A%84%E5%80%BC%201.7%20%E5%B7%B2%E6%9B%B4%E6%96%B0%EF%BC%8C%E4%BD%86%20USL%20%E5%92%8C%20LSL%20%E5%88%97%E5%B1%AC%E6%80%A7%E6%9C%AA%E6%9B%B4%E6%96%B0%E3%80%82%20%E5%A6%82%E6%9E%9C%E6%88%91%E5%B0%87%20Speclimit%20%E8%AE%8A%E6%95%B8%E8%A8%AD%E7%82%BA%E5%B8%B8%E6%95%B8%201.7%EF%BC%8C%E5%89%87%20USL%20%E5%92%8C%20LSL%20%E5%88%97%E5%B1%AC%E6%80%A7%E5%B0%87%E5%88%86%E5%88%A5%E8%A8%AD%E7%82%BA%201.7%20%E5%92%8C%20-1.7%E3%80%82%20%E6%89%80%E4%BB%A5%E5%95%8F%E9%A1%8C%E4%B8%80%E5%AE%9A%E6%98%AF%E5%BE%9E%E6%96%87%E5%AD%97%E6%AA%94%E4%B8%AD%E5%8F%96%E5%BE%97%E5%80%BC%EF%BC%8C%E4%BD%86%E6%88%91%E5%8F%AF%E4%BB%A5%E6%89%BE%E5%87%BA%E5%95%8F%E9%A1%8C%E6%89%80%E5%9C%A8%E3%80%82%20%E6%9C%89%E4%BA%BA%E5%8F%AF%E4%BB%A5%E8%AE%93%E6%88%91%E7%9F%A5%E9%81%93%E5%BE%9E%E6%96%87%E5%AD%97%E6%AA%94%E6%A1%88%E5%8F%96%E5%BE%97%E8%A6%8F%E6%A0%BC%E9%99%90%E5%88%B6%E4%B8%A6%E8%AE%93%E5%AE%83%E6%9B%B4%E6%96%B0%E5%88%97%E5%B1%AC%E6%80%A7%E7%9A%84%E8%A7%A3%E6%B1%BA%E6%96%B9%E6%A1%88%E6%98%AF%E4%BB%80%E9%BA%BC%E5%97%8E%EF%BC%9F%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22%20language-jsl%22%3EInclude(%20%22%24CommonScriptPath%2FFunction%20-%20Obtain%20Spec%20Limit%20Value.jsl%22%20)%3B%0ASpeclimit%20%3D%20ObtainSpecLimit(%0A%20Ntwk%20Osnr%20Spec%20Table%20Filename%2C%20DeviceType%2C%20%22*%22%2C%20%22*%22%2C%20%22ber_diffQcalc%22%0A)%3B%0A%0Adt%20%3D%20Open(%20Ntwk%20Osnr%20Data%20Table%20Filename%2C%20invisible%20)%3B%0AData%20Table(%20dt%20)%3APctDiff_ModBer_q_calcBer%20%26lt%3B%26lt%3B%20Set%20Property(%0A%20%22Spec%20Limits%22%2C%0A%20%7BLSL(%20(Speclimit%20*%20(-1))%20)%2C%20USL(%20Speclimit%20)%2C%20Target(%200%20)%2C%20Show%20Limits(%201%20)%7D%0A)%3B%3C%2FCODE%3E%3C%2FPRE%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-480402%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%3CLINGO-LABEL%3E%E9%80%B2%E9%9A%8E%E7%B5%B1%E8%A8%88%E5%BB%BA%E6%A8%A1%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3E%E8%87%AA%E5%8B%95%E5%8C%96%E5%92%8C%E8%85%B3%E6%9C%AC%E7%B7%A8%E5%AF%AB%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3E%E6%B6%88%E8%B2%BB%E8%80%85%E8%88%87%E5%B8%82%E5%A0%B4%E7%A0%94%E7%A9%B6%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3E%E8%B3%87%E6%96%99%E6%B7%B7%E5%90%88%E8%88%87%E6%B8%85%E7%90%86%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3E%E5%A4%A7%E8%A6%8F%E6%A8%A1%E5%AE%A2%E8%A3%BD%E5%8C%96%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-480422%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%E5%9B%9E%E8%A6%86%EF%BC%9A%E6%9B%B4%E6%94%B9%E5%88%97%20USL%20%E5%92%8C%20LSL%20%E5%B1%AC%E6%80%A7%E7%9A%84%20JMP%20%E8%85%B3%E6%9C%AC%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-480422%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%3CP%3E%E6%82%A8%E5%9C%A8%20JMP%20%E6%B8%85%E5%96%AE%E4%B8%AD%E6%8C%87%E5%AE%9A%E7%9A%84%E8%A8%88%E7%AE%97%E5%9C%A8%E5%9F%B7%E8%A1%8C%E4%B9%8B%E5%89%8D%E4%B8%8D%E6%9C%83%E9%80%B2%E8%A1%8C%E8%A9%95%E4%BC%B0%E3%80%82%E5%9B%A0%E6%AD%A4%EF%BC%8C%E5%9C%A8%20Substitution%20%E5%87%BD%E6%95%B8%E5%AE%8C%E6%88%90%E8%A9%B2%E6%93%8D%E4%BD%9C%E4%B9%8B%E5%89%8D%EF%BC%8C%E5%BF%85%E9%A0%88%E5%B0%8D%E8%A9%B2%E8%AA%9E%E5%8F%A5%E9%80%B2%E8%A1%8C%E5%AE%8C%E5%85%A8%E8%A7%A3%E6%9E%90%E5%92%8C%E8%A9%95%E4%BC%B0%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22%20language-jsl%22%3EInclude(%20%22%24CommonScriptPath%2FFunction%20-%20Obtain%20Spec%20Limit%20Value.jsl%22%20)%3B%0ASpeclimit%20%3D%20ObtainSpecLimit(%0A%20Ntwk%20Osnr%20Spec%20Table%20Filename%2C%20DeviceType%2C%20%22*%22%2C%20%22*%22%2C%20%22ber_diffQcalc%22%0A)%3B%0A%0Adt%20%3D%20Open(%20Ntwk%20Osnr%20Data%20Table%20Filename%2C%20invisible%20)%3B%0A%0AEval(%0A%20Substitute(%0A%20%20%20Expr(%0A%20%20%20%20Data%20Table(%20dt%20)%3APctDiff_ModBer_q_calcBer%20%26lt%3B%26lt%3B%0A%20%20%20%20Set%20Property(%0A%20%20%20%20%20%22Spec%20Limits%22%2C%0A%20%20%20%20%20%7BLSL(%20__LSL__%20)%2C%20USL(%20__USL__%20)%2C%20Target(%200%20)%2C%20Show%20Limits(%201%20)%7D%0A%20%20%20%20)%0A%20%20%20)%2C%0A%20%20Expr(%20__LSL__%20)%2C%20Speclimit%20*%20(-1)%2C%0A%20%20Expr(%20__USL__%20)%2C%20Speclimit%0A%20)%0A)%3B%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-480421%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%E5%9B%9E%E8%A6%86%EF%BC%9A%E6%9B%B4%E6%94%B9%E5%88%97%20USL%20%E5%92%8C%20LSL%20%E5%B1%AC%E6%80%A7%E7%9A%84%20JMP%20%E8%85%B3%E6%9C%AC%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-480421%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%3CP%3E%E7%A2%BA%E4%BF%9D%E5%80%BC%E6%98%AF%E6%95%B8%E5%AD%97%E4%B8%A6%E5%98%97%E8%A9%A6%E4%BD%BF%E7%94%A8%20Eval(EvalExpr())%20%E5%92%8C%20Expr()%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22%20language-jsl%22%3EInclude(%22%24CommonScriptPath%2FFunction%20-%20Obtain%20Spec%20Limit%20Value.jsl%22)%3B%0ASpeclimit%20%3D%20ObtainSpecLimit(Ntwk%20Osnr%20Spec%20Table%20Filename%2C%20DeviceType%2C%20%22*%22%2C%20%22*%22%2C%20%22ber_diffQcalc%22)%3B%0A%0Adt%20%3D%20Open(Ntwk%20Osnr%20Data%20Table%20Filename%2C%20invisible)%3B%0AEval(%0A%20Eval%20Expr(%0A%20%20Data%20Table(dt)%3APctDiff_ModBer_q_calcBer%20%26lt%3B%26lt%3B%20Set%20Property(%0A%20%20%20%22Spec%20Limits%22%2C%0A%20%20%20%7BLSL(Expr(Speclimit%20*%20(-1)))%2C%20USL(Expr(Speclimit))%2C%20Target(0)%2C%20Show%20Limits(1)%7D%0A%20%20)%0A%20)%0A)%3B%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fcommunity.jmp.com%2Ft5%2FJSL-Cookbook-Archived%2FInsert-one-expression-into-another-using-Eval-Insert-Eval-Expr%2Fm-p%2F48998%23U48998%22%20class%3D%22lia-mention-container-editor-message%20lia-img-icon-tkb-thread%20lia-fa-icon%20lia-fa-tkb%20lia-fa-thread%20lia-fa%22%20target%3D%22_blank%22%3E%E4%BD%BF%E7%94%A8%20Eval%20Insert%E3%80%81Eval%20Expr%E3%80%81Parse%20%E5%92%8C%20Substitute%20%E5%B0%87%E4%B8%80%E5%80%8B%E8%A1%A8%E9%81%94%E5%BC%8F%E6%8F%92%E5%85%A5%E5%8F%A6%E4%B8%80%E5%80%8B%E8%A1%A8%E9%81%94%E5%BC%8F%3C%2FA%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E
Choose Language Hide Translation Bar
kprentiss
Level I

JMP Script that changes the column USL and LSL properties

I have a JMP Script Function that obtains a set of spec limits from a text file that is stored within the "Ntwk Osnr Spec Table Filename" variable. I am trying to change the USL and LSL column properties of the "PctDiff_ModBer_q_calcBer column within the "Ntwk Osnr Data Table" data table. But when I run the following JMP script commands I do not get a scripting error but the USL and LSL column properties are not updated. The Spec Limit that is obtained from the spec limit is 1.7. When I step thru the following lines the value of 1.7 is updated within the Speclimit variable but the USL  and LSL Column Properties are not updated. If I set the Speclimit variable to a constant 1.7 then the USL and LSL Column Properties are set to 1.7 and -1.7 respectively. So the issue must be obtaining the value from the text file, but I can figure out the issue. Can some one let me know what the solution is to obtain the spec limit from a text file and have it update the column properties.

 

Include( "$CommonScriptPath/Function - Obtain Spec Limit Value.jsl" );
Speclimit = ObtainSpecLimit(
	Ntwk Osnr Spec Table Filename, DeviceType, "*", "*", "ber_diffQcalc"
);

dt = Open( Ntwk Osnr Data Table Filename, invisible );
Data Table( dt ):PctDiff_ModBer_q_calcBer << Set Property(
	"Spec Limits",
	{LSL( (Speclimit * (-1)) ), USL( Speclimit ), Target( 0 ), Show Limits( 1 )}
);
2 REPLIES 2
jthi
Super User

Re: JMP Script that changes the column USL and LSL properties

Make sure the values are numeric and try using Eval(EvalExpr()) and Expr()

Include("$CommonScriptPath/Function - Obtain Spec Limit Value.jsl");
Speclimit = ObtainSpecLimit(Ntwk Osnr Spec Table Filename, DeviceType, "*", "*", "ber_diffQcalc");

dt = Open(Ntwk Osnr Data Table Filename, invisible);
Eval(
	Eval Expr(
		Data Table(dt):PctDiff_ModBer_q_calcBer << Set Property(
			"Spec Limits",
			{LSL(Expr(Speclimit * (-1))), USL(Expr(Speclimit)), Target(0), Show Limits(1)}
		)
	)
);

Insert one expression into another using Eval Insert, Eval Expr, Parse, and Substitute 

-Jarmo
txnelson
Super User

Re: JMP Script that changes the column USL and LSL properties

The calculations you are specifying within a JMP List, will not be evaluated prior to execution.  Therefore, the statement must be fully parsed and evaluated before  The Substitution function will accomplish that

Include( "$CommonScriptPath/Function - Obtain Spec Limit Value.jsl" );
Speclimit = ObtainSpecLimit(
	Ntwk Osnr Spec Table Filename, DeviceType, "*", "*", "ber_diffQcalc"
);

dt = Open( Ntwk Osnr Data Table Filename, invisible );

Eval(
	Substitute(
			Expr(
				Data Table( dt ):PctDiff_ModBer_q_calcBer <<
				Set Property(
					"Spec Limits",
					{LSL( __LSL__ ), USL( __USL__ ), Target( 0 ), Show Limits( 1 )}
				)
			),
		Expr( __LSL__ ), Speclimit * (-1),
		Expr( __USL__ ), Speclimit
	)
);

 

Jim