I have a script that plots the distribution of a column's data and fits a normal curve to it. Is there any way to automaticaly set upper/lower specs based on this fit normal and k sigma values known within the script?
Better yet, is there a way to automate the plotting of reference lines on the quantile plot showing where a spec should be set to achieve a k sigma of 3?
Hi,
Have you tried the Scripting Index? You can find useful functions there.
To understand how a scripting solution might work you can apply some spec limits as column properties using the point-and-click. Then have a look at the table script. For example I added spec limits of 55 to 60 to a column in the Big Class data example. Looking in the table script for that column I found the syntax for spec limit properties:
Set Property( "Spec Limits", {LSL( 55 ), USL( 60 ), Show Limits( 0 )} )
(Notice this also has the instruction for whether or not the limits are shown on plots).
Then search in the scripting index for an example on how to set column properties:
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
:Weight << Set Property( "Units", lbs );
I think you should just need a couple of other functions to calculate what the spec limits should be: Col Mean() and Col Std Dev().
Hope that helps.
Phil