BookmarkSubscribe
Choose Language Hide Translation Bar

How can insert custom parameter in the stat summary.

Besides commonly used quality capability performance indices (Cp, Cpk, Pp, Ppk), my company also uses K-index.  K=|Xbar-T|/(min(USL-T, T-LSL)). Basically it is similar to Ppk, except that it gives a non-statistical manager a quick glance of process mean deviation from the target in percent.  Some prefer not use the absolute numerator.  Then +/- sign indicate if process is under or over spec target,

Once I enter the LSL/USL in column properties or capability under distribution platform, I calculate K manually, which is time-consuming, especially if I have many specs.  Can I program this formula in the JSL?  I am fairly new to JSL and I want to learn how to do it.

3 REPLIES 3

Re: How can insert custom parameter in the stat summary.

You can do what you are talking about.  Here is a script that illustrates it.using the Semiconductor Capability sample data table:

Names Default To Here( 1 );

dt = Open( "\$SAMPLE_DATA\semiconductor capability.jmp" );

dis = dt << Distribution( Continuous Distribution( Column( :NPN1 ) ) );

// Calculate K

k = ((Report( dis )["Summary Statistics"] << get) - (dt:NPN1 << get property( "Spec Limits" ))["Target"]) /

Min(

((dt:NPN1 << get property( "Spec Limits" ))["USL"]) - (dt:NPN1 << get property( "Spec Limits" ))["Target"],

(dt:NPN1 << get property( "Spec Limits" ))["Target"] - (dt:NPN1 << get property( "Spec Limits" ))["LSL"]

);

// Put into the display

// Place the k value into a list

klist = {};

Insert Into( klist, k );

ob = Outline Box( "K Value", Table Box( Number Col Box( "K Value", klist ) ) );

Report( dis )["Capability Analysis"] << prepend( ob ); Jim

Re: How can insert custom parameter in the stat summary.

Thank you so much Jim.  That looks awesome!  I think this is what I need.  Can you please also advise me what is the best way to keep this script as "handy tool" in order to apply for different data tables.

Thank you,

Re: How can insert custom parameter in the stat summary.

Here is a script that will generate the Distribution output for all columns in a data table that has LSL, USL, and Target

Names Default To Here( 1 );

dt = Open( "\$SAMPLE_DATA\semiconductor capability.jmp" );

columnList = dt << get column names( numeric, string );

NW = New Window( "Distributions", HLB = H List Box() );

For( i = 1, i <= N Items( columnList ), i++,

If(

Is Empty( Try( (Column( dt, columnList[i] ) << get property( "Spec Limits" ))["USL"] ) ) == 0 & Is Empty(

Try( (Column( dt, columnList[i] ) << get property( "Spec Limits" ))["LSL"] )

) == 0 & Is Empty( Try( (Column( dt, columnList[i] ) << get property( "Spec Limits" ))["Target"] ) ) == 0,

dis = Distribution( Continuous Distribution( Column( column(dt,columnList[i]) ) ) );

// Calculate K

k = ((Report( dis )["Summary Statistics"] << get) - (Column( dt, columnList[i] ) << get property( "Spec Limits" ))["Target"]) /

Min(

((Column( dt, columnList[i] ) << get property( "Spec Limits" ))["USL"]) - (Column( dt, columnList[i] ) << get property( "Spec Limits" ))[

"Target"],

(Column( dt, columnList[i] ) << get property( "Spec Limits" ))["Target"] - (Column( dt, columnList[i] ) << get property( "Spec Limits" ))

["LSL"]

);

// Put into the display

// Place the k value into a list

klist = {};

Insert Into( klist, k );

ob = Outline Box( "K Value", Table Box( Number Col Box( "K Value", klist ) ) );

Report( dis )["Capability Analysis"] << prepend( ob );

HLB << append( Report(dis) );

dis << close window;

)

);

Jim