Subscribe Bookmark RSS Feed

How to eliminate the moving range portion of a control chart

frankeberle

Community Trekker

Joined:

Jun 2, 2016

I have a script where I generate a control chart from the builder.  I basically just formatted the chart how I wanted manually and then saved the script to script window and used that in my script.  The problem is that even though in the making of the graph I had eliminated the moving range portion of the chart and then saved the script the moving range keeps coming back.  I know that you are supposed to use the syntax: Show Two Shewhart Charts( 0 ), to remove the moving range but even though it is in the script it doesn't eliminate it.  The script is as follows:

lower_spec = num(Col Mean( LowerSpec ));

    upper_spec = num(Col Mean( UpperSpec ));

    up_control = num(ucont);

    low_control = num(lcont);

    max_number = num(col max(column(4)));

    min_number = num(col min(column(4)));

    if(max_number > upper_spec, chart_max = max_number,chart_max = upper_spec);

    if(min_number < lower_spec, chart_min = min_number,chart_min = lower_spec);

    Control Chart Builder(

        Show Two Shewhart Charts( 0 ),

        Size( 450, 900 ),

        Show Control Panel( 0 ),

        Include Missing Categories( 0 ),

        Variables( Subgroup( :lot ), Y( :column( 4 ), Individual Measurement) ),

        Chart(

            Points( Statistic( "Individual" ) ),

            Limits( Sigma( "User Defined" ) ),

            Set Control Limits( {LCL( low_control ), UCL( up_control )} ),

            Add Spec Limits( {LSL( lower_spec ), USL( upper_spec ), Target( desired )} )

        ),

        SendToReport(

            Dispatch(

                {},

                ScaleBox,

                {Min( chart_min * 0.95 ), Max( chart_max * 1.05 ),Add Ref Line( lower_spec, "Solid", "Blue", "LSL", 1 ), Add Ref Line( upper_spec, "Solid", "Blue", "USL", 1 ),

                Add Ref Line( desired, "Solid", "Blue", "Target", 1 ),

                Add Ref Line( low_control, "Solid", "Red", "LCL", 1 ),

                Add Ref Line( up_control, "Solid", "Red", "UCL", 1 )

                }

            ),

            Dispatch( {"Process Capability Analysis", "Histogram"}, "Process Capability Analysis Histogram", FrameBox, {Frame Size( 150, 18 )} ),

            Dispatch(

                {"Process Capability Analysis", "Histogram"},

                "Process Capability Analysis Histogram",

                FrameBox( 2 ),

                {Frame Size( 150, 160 )}

            ),

            Dispatch( {"Process Capability Analysis", "Process Summary"}, "Within sigma estimated by moving range.", TextBox, {Set Wrap( 75 )} )

        )

    );

Is it a bug that needs to be addressed or am I not coding this right?

Thanks in advance for any help.

1 REPLY
tonya_mauldin0

Joined:

Jan 21, 2015

I tried your code in both JMP 12.2 and 13.0 and it ran as expected.  In both versions, only the Individuals chart was produced.  What version are you using?  Do you have any nondefault preferences? 

If you are still having problem with this, please send your information to support@jmp.com and technical support can help resolve this for you.