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.
Choose Language Hide Translation Bar
Mikasa
Level II

how to set the control limit for a column using other columns?

Hi every one.

I know this question might be repeated. I have read all answers for example Getting control limits from column property 

 

I have a column (:X) and I have three columns for :X control limits,  (UCL,LCL, Ave). and I like to set the control limits to :X, but I am confused.

I tried ;

 

:X<<Set Property("Control Limits", {XBar(Ave(:Center Line[1]),LCL( :Lower Limit[1] ), UCL( Upper Limit[1] )), Show Control Limits( 1)});

But it does not work.

 

Also, sometimes in UCL,LCL, and AVE columns, I have different values for different rows in :X

I know it is not possible to have different set of Spec limits for a Colum but I was wondering if there is a way to do that for Control limit.

Thanks

 

12 REPLIES 12
Byron_JMP
Staff

Re: how to set the control limit for a column using other columns?

@txnelson   I'm pretty sure you're right. 

 

Do you think it would be possible to have an axis property reference a control limit property?

JMP Systems Engineer, Health and Life Sciences (Pharma)

Re: how to set the control limit for a column using other columns?

Some JMP platforms might use more than one column property, but they are not linked in any way, if that is what you are asking. Your script would have to use 'setter and getter' actions to coordinate anything beyond what JMP does automatically.

txnelson
Super User

Re: how to set the control limit for a column using other columns?

Here is a simple example that 

  1. Populates the Control Limits for a column
  2. Runs a Distribution Platform
  3. Adds the Control Limits from the displayed column on the graphical output

controllimits.PNG

names default to here(1);

// Open a sample data table
dt=open("$SAMPLE_DATA/big class.jmp" );

// Add a column to be used as the subgroup
dt << new column( "group", formula(Mod(Row(), 4)));

// Add the Control Limits columns to the data table
dt << new column("Center Line", set values({62.55}));
dt << new column("Lower Limit", set values({58.08}));
dt << new column("Upper Limit", set values({67.02}));

// Set the name of the Height column to match the previously distributed
// code
dt:height << set name("X");


// Set the column Property for the Control Limits
Eval(
	Substitute(
			Expr(
				:X << Set Property(
					"Control Limits",
					{XBar( avg( __avg__ ), LCL( __LCL__ ), UCL( __UCL__ ) )}
				)
			),
		Expr( __avg__ ), :Center Line[1],
		Expr( __LCL__ ), :Lower Limit[1],
		Expr( __UCL__ ), :Upper Limit[1]
	)
);

// Run a platform that creates a graph
dist = Distribution( Continuous Distribution( Column( :X ) ) );

// Extract the Control Limits from the column
contLimits = :X << get property("Control Limits");

// Parse through the returned Limits to get the LCL, UCL and Avg
contLimits=char(contLimits);
found=contains(contLimits,"XBar");
contLimits=substr(contLimits,found+5);
found=contains(contLimits,"avg");
contLimits=substr(contLimits,found+4);
theAvg = num( word(1,contLimits,")"));
found=contains(contLimits,"LCL");
contLimits=substr(contLimits,found+4);
theLCL = num( word(1,contLimits,")"));
found=contains(contLimits,"UCL");
contLimits=substr(contLimits,found+4);
theUCL = num( word(1,contLimits,")"));

// Add reference lines to the graph with the Control Limit values
report(dist)[AxisBox(1)] << add ref line(theLCL,Solid,Black,"LCL");
report(dist)[AxisBox(1)] << add ref line(theUCL,Solid,Black,"UCL");
report(dist)[AxisBox(1)] << add ref line(theAvg,Solid,Black,"Ave");
Jim