cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Browse apps to extend the software in the new JMP Marketplace
Choose Language Hide Translation Bar
Djbrun
Level I

How do I use a script to save control chart limits to a new table?

I need help creating a script that will create a new table containing the UCL LCL and Average from a control chart.

The control chart is created by a script using data from an excel file. I need the UCL LCL and Average to go back into the original excel file.

 

I have found reference to a "Save Limits" option for control charts in JMP but I'm not sure how to use it or if it is even appropriate for me needs.

1 ACCEPTED SOLUTION

Accepted Solutions

Re: How do I use a script to save control chart limits to a new table

Use the in column command to save the limits to the column.  Here is an example.

dt = Open("$SAMPLE_DATA/Quality Control/Diameter.jmp");
obj = dt<<Control Chart Builder(
	Variables( "Subgroup"(:DAY), "Y"(:DIAMETER) ),
	Chart(
		Position( 1 ),
		Points( Statistic( "Average" ) ),
		Limits( Sigma( "Range" ) ),
		Connecting Line( 1 )
	),
	Chart(
		Position( 2 ),
		Points( Statistic( "Range" ) ),
		Limits( Sigma( "Range" ) ),
		Connecting Line( 1 )
	)
);

obj << in Column; // *Save Limits in Column*

View solution in original post

5 REPLIES 5
txnelson
Super User

Re: How do I use a script to save control chart limits to a new table

If you use the Control Chart Builder, the only option available is to Save to Column, which saves the limits to the columns's "Control Limits, column property".  A simple script could move these values to a JMP data table.

However, if you use one of the other Control Chart platforms, such as Xbar, etc. They have the option of saving the limits to a table.

 

So either option will work.

Jim
Djbrun
Level I

Re: How do I use a script to save control chart limits to a new table

Is there a way to save the control limits to the column using a script? So far I have had to do that manually.

txnelson
Super User

Re: How do I use a script to save control chart limits to a new table

The answer is:    Of course

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/semiconductor capability.jmp" );
dt:npn1 << set property( "control limits", 
	({XBar( Avg( 115 ), LCL( 112 ), UCL( 118 ) )}) );

This is a very simple example, but it can be built on.  One would need to know the table structure of the limits coming in, and then it would have to be able to match up the input from the limits table to the data table you are populating.  If you are looking for a JMP Platform to do this, I am working on an Addin to do this precise thing.  It should be available by the end of this week, in the File Exchange.

Jim

Re: How do I use a script to save control chart limits to a new table

Use the in column command to save the limits to the column.  Here is an example.

dt = Open("$SAMPLE_DATA/Quality Control/Diameter.jmp");
obj = dt<<Control Chart Builder(
	Variables( "Subgroup"(:DAY), "Y"(:DIAMETER) ),
	Chart(
		Position( 1 ),
		Points( Statistic( "Average" ) ),
		Limits( Sigma( "Range" ) ),
		Connecting Line( 1 )
	),
	Chart(
		Position( 2 ),
		Points( Statistic( "Range" ) ),
		Limits( Sigma( "Range" ) ),
		Connecting Line( 1 )
	)
);

obj << in Column; // *Save Limits in Column*
txnelson
Super User

Re: How do I use a script to save control chart limits to a new table

I believe that Tonya has the correct answer.....I was approaching the issue from a different angle

Jim