Subscribe Bookmark RSS Feed

Clear row states after closing IR Chart

Raquel

New Contributor

Joined:

Jun 30, 2017

Hello, is there a way to clear row states after closing an IR chart? If I put the following at the end of the script, the row states get cleared before the chart is created. Thanks.

 

Data Table( "XYZ") << Clear Row States;

1 ACCEPTED SOLUTION

Accepted Solutions
txnelson

Super User

Joined:

Jun 22, 2012

Solution

What you are seeing is the way that JMP dynamically handles colors.  If you notice on the control charts, it has a message indicating how many data points were excluded, when the chart was run.  So those points are not being changed with your << Clear Row States.  But JMP is and will continue to changes the colors in all of your graphs dynamically, when colors are changed.  So what you need to do is to preserve the chart as it is, before do the << Clear Row States;

If you change your code to the following, it will generate a Journal copy of your control chart, with the values preserved

cc=Control Chart(
	Sample Label( :Column A ),
	Group Size( 1 ),
	KSigma( 3 ),
	Connect Through Missing( 0 ),
	Chart Col( :Height, Individual Measurement( Connect Points( 0 ) ), Moving Range )
);
report(cc)<<journal;
Data Table( "Big Class" ) << Clear Row States;
Jim
4 REPLIES
txnelson

Super User

Joined:

Jun 22, 2012

I can not replicate that behavior in JMP 13.  Can you provide the script that you are using?

Jim
Raquel

New Contributor

Joined:

Jun 30, 2017

I want the scripted row states to stay on the IR chart and clear the row states in the Data Table once the chart has been closed. However, Clear Row States at the end of the script clears the row states on the created IR chart:

 

Data Table( "XYZ" ) << Clear Row States;

df = Current Data Table() << Data Filter(

      Location( {295, 205} ),

      Add Filter( columns( :Column A ), Where( :Column A >= 2 & :Column A <= 2 ) )

) << exclude;

Current Data Table() << Clear Select;

df << close;

 

df = Current Data Table() << Data Filter(

      Add Filter(

            columns( :Name( "Column B" ) ),

            Where(

                  :Name( "Column B" ) >= 0 & :Name( "Column B" ) <= 50

            )

      ),

)<< hide << exclude;

Current Data Table()<< Clear Select;

df << close;

 

Current Data Table() << Color by Column(

      Column A,

      Color( 1 ),

      Color Theme( "JMP Default" ),

      Marker( 0 ),

      Marker Theme( "" ),

      Continuous Scale( 0 ),

      Reverse Scale( 0 ),

      Excluded Rows( 0 )

);

 

Control Chart(

      Sample Label( :Column A ),

      Group Size( 1 ),

      KSigma( 3 ),

      Connect Through Missing( 0 ),

      Chart Col(

            :Column B,

            Individual Measurement( Connect Points( 0 ) ),

            Moving Range

      )

);

Data Table( "XYZ" ) << Clear Row States;

 

txnelson

Super User

Joined:

Jun 22, 2012

Solution

What you are seeing is the way that JMP dynamically handles colors.  If you notice on the control charts, it has a message indicating how many data points were excluded, when the chart was run.  So those points are not being changed with your << Clear Row States.  But JMP is and will continue to changes the colors in all of your graphs dynamically, when colors are changed.  So what you need to do is to preserve the chart as it is, before do the << Clear Row States;

If you change your code to the following, it will generate a Journal copy of your control chart, with the values preserved

cc=Control Chart(
	Sample Label( :Column A ),
	Group Size( 1 ),
	KSigma( 3 ),
	Connect Through Missing( 0 ),
	Chart Col( :Height, Individual Measurement( Connect Points( 0 ) ), Moving Range )
);
report(cc)<<journal;
Data Table( "Big Class" ) << Clear Row States;
Jim
Raquel

New Contributor

Joined:

Jun 30, 2017

Thanks so much! I added 1 line to close an extra chart window that was generated. Now it's working just how I wanted it to.

 

report(cc)<<journal;
cc<<Close Window;
Data Table("XYZ")<< Clear Row States;