<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How to connect column switcher and local data filter together in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-to-connect-column-switcher-and-local-data-filter-together/m-p/475457#M71994</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Here is my not quite working script.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;test = Fit Group(
	Oneway(
		Y( :Max Discharge Capacity ),
		X( :Cathode Recipe.x ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ),
		
	),
	
	Oneway(
		Y( :"Cycle Number (&amp;gt;0.3)"n ),
		X( :Cathode Recipe.x ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ),
		
	),
	Oneway(
		Y( :"Discharge Capacity @ 50 Cycles"n ),
		X( :Cathode Recipe.x ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ),
	),
	Oneway(
		Y( :"Remain % @ 50 Cycles"n ),
		X( :Cathode Recipe.x ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ),
		
	),

	&amp;lt;&amp;lt;{Arrange in Rows( 4 )}
);
colpick=test &amp;lt;&amp;lt; Column Switcher(
	:Cathode Recipe.x,
	{:Cathode Batch ID.x, :Anode Batch ID.x, :Electrolyte Recipe.x, :Anode Recipe.x, :Separator Recipe.x, :Separator Batch ID.x}
);
test &amp;lt;&amp;lt; Local Data Filter(
	Add Filter(
		columns( colpick&amp;lt;&amp;lt; get current ),
		Display( colpick&amp;lt;&amp;lt; get current, N Items( 15 ), Find( Set Text( "" ) ) )
	)
);&lt;/CODE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;P&gt;The column switcher is created and works as expected. &amp;nbsp;What I would like to happen is when the column is switched that the local data filter is updated with the respective values of that column to allow the user to further refine their view of the data. I think I am close. &amp;nbsp;How should the local data filter be coded to get the column switcher column and then update?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="image.png" style="width: 999px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/41435iF65F0A6F435FCDFF/image-size/large?v=v2&amp;amp;px=999" role="button" title="image.png" alt="image.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in Advance&lt;/P&gt;&lt;P&gt;Andy&lt;/P&gt;</description>
    <pubDate>Fri, 09 Jun 2023 18:15:05 GMT</pubDate>
    <dc:creator>Hegedus1</dc:creator>
    <dc:date>2023-06-09T18:15:05Z</dc:date>
    <item>
      <title>How to connect column switcher and local data filter together</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-connect-column-switcher-and-local-data-filter-together/m-p/475457#M71994</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Here is my not quite working script.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;test = Fit Group(
	Oneway(
		Y( :Max Discharge Capacity ),
		X( :Cathode Recipe.x ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ),
		
	),
	
	Oneway(
		Y( :"Cycle Number (&amp;gt;0.3)"n ),
		X( :Cathode Recipe.x ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ),
		
	),
	Oneway(
		Y( :"Discharge Capacity @ 50 Cycles"n ),
		X( :Cathode Recipe.x ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ),
	),
	Oneway(
		Y( :"Remain % @ 50 Cycles"n ),
		X( :Cathode Recipe.x ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ),
		
	),

	&amp;lt;&amp;lt;{Arrange in Rows( 4 )}
);
colpick=test &amp;lt;&amp;lt; Column Switcher(
	:Cathode Recipe.x,
	{:Cathode Batch ID.x, :Anode Batch ID.x, :Electrolyte Recipe.x, :Anode Recipe.x, :Separator Recipe.x, :Separator Batch ID.x}
);
test &amp;lt;&amp;lt; Local Data Filter(
	Add Filter(
		columns( colpick&amp;lt;&amp;lt; get current ),
		Display( colpick&amp;lt;&amp;lt; get current, N Items( 15 ), Find( Set Text( "" ) ) )
	)
);&lt;/CODE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;P&gt;The column switcher is created and works as expected. &amp;nbsp;What I would like to happen is when the column is switched that the local data filter is updated with the respective values of that column to allow the user to further refine their view of the data. I think I am close. &amp;nbsp;How should the local data filter be coded to get the column switcher column and then update?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="image.png" style="width: 999px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/41435iF65F0A6F435FCDFF/image-size/large?v=v2&amp;amp;px=999" role="button" title="image.png" alt="image.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in Advance&lt;/P&gt;&lt;P&gt;Andy&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 18:15:05 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-connect-column-switcher-and-local-data-filter-together/m-p/475457#M71994</guid>
      <dc:creator>Hegedus1</dc:creator>
      <dc:date>2023-06-09T18:15:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to connect column switcher and local data filter together</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-connect-column-switcher-and-local-data-filter-together/m-p/475479#M71995</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/26798"&gt;@Hegedus1&lt;/a&gt;&amp;nbsp; (Andy),&amp;nbsp; This might one help:&amp;nbsp;&amp;nbsp;&lt;LI-MESSAGE title="Column Switcher, Local Data Filter and Ref Line Automatically Update" uid="324936" url="https://community.jmp.com/t5/Discussions/Column-Switcher-Local-Data-Filter-and-Ref-Line-Automatically/m-p/324936#U324936" discussion_style_icon_css="lia-mention-container-editor-message lia-img-icon-forum-thread lia-fa-icon lia-fa-forum lia-fa-thread lia-fa"&gt;&lt;/LI-MESSAGE&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 04 Apr 2022 16:03:14 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-connect-column-switcher-and-local-data-filter-together/m-p/475479#M71995</guid>
      <dc:creator>PatrickGiuliano</dc:creator>
      <dc:date>2022-04-04T16:03:14Z</dc:date>
    </item>
    <item>
      <title>Re: How to connect column switcher and local data filter together</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-connect-column-switcher-and-local-data-filter-together/m-p/475482#M71996</link>
      <description>&lt;P&gt;Here is a rework of your code, usiing the Semiconductor Capability sample data table.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="txnelson_0-1648897604733.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/41436iC4BC49373128377B/image-size/medium?v=v2&amp;amp;px=400" role="button" title="txnelson_0-1648897604733.png" alt="txnelson_0-1648897604733.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="txnelson_1-1648897636775.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/41437i90D77B5A8CDE8E72/image-size/medium?v=v2&amp;amp;px=400" role="button" title="txnelson_1-1648897636775.png" alt="txnelson_1-1648897636775.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
// Open Data Table: semiconductor capability.jmp
// → Data Table( "semiconductor capability" )
dt = Open( "$SAMPLE_DATA/semiconductor capability.jmp" );
test = Fit Group(
	Oneway(
		Y( :NPN1 ),
		X( :Site ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ), 
		
	), 
	
	Oneway(
		Y( :PNP1 ),
		X( :Site ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ), 
		
	),
	Oneway(
		Y( :NPN2 ),
		X( :Site ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ),

	),
	Oneway(
		Y( :PNP2 ),
		X( :Site ),
		Quantiles( 1 ),
		Means( 1 ),
		Box Plots( 1 ),
		Mean Diamonds( 0 ),
		X Axis Proportional( 0 ),
		Points Jittered( 1 ),
		Grand Mean( 0 ), 
		
	), 

	&amp;lt;&amp;lt;{Arrange in Rows( 4 )}
);

// Set the Column Switcher
colpick = test &amp;lt;&amp;lt; Column Switcher( :Site, {:lot_id, :wafer, :site, :wafer id in lot id} );

// Add a script to the Column Switcher to change the Local Data Filter
// whenever the selection in the Column Switcher is changed.  When a change
// is detected, the existing Local Data Filter is deleted and a new one
// is created, with the new column that was selected in the Column Switcher
(test &amp;lt;&amp;lt; top parent)[listboxbox( 1 )] &amp;lt;&amp;lt; set script(
	Try( test &amp;lt;&amp;lt; remove local data filter );
	mycurrent = ((test&amp;lt;&amp;lt;top parent)[listboxbox(1)]&amp;lt;&amp;lt; get selected)[1];
	test &amp;lt;&amp;lt; Local Data Filter(
		Add Filter(
			columns( column(mycurrent) ),
			Display( column(mycurrent), N Items( 15 ), Find( Set Text( "" ) ) )
		)
	);
);

// Create the initial Local Data Filter
test &amp;lt;&amp;lt; Local Data Filter(
		Add Filter(
			columns( colpick &amp;lt;&amp;lt; get current ),
			Display( colpick &amp;lt;&amp;lt; get current, N Items( 15 ), Find( Set Text( "" ) ) )
		)
	);
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 02 Apr 2022 11:08:38 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-connect-column-switcher-and-local-data-filter-together/m-p/475482#M71996</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2022-04-02T11:08:38Z</dc:date>
    </item>
    <item>
      <title>Re: How to connect column switcher and local data filter together</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-connect-column-switcher-and-local-data-filter-together/m-p/475527#M72002</link>
      <description>&lt;P&gt;Thank you that is exactly what I needed. &amp;nbsp;And I would never of figured that out on my own.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 02 Apr 2022 14:51:34 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-connect-column-switcher-and-local-data-filter-together/m-p/475527#M72002</guid>
      <dc:creator>Hegedus1</dc:creator>
      <dc:date>2022-04-02T14:51:34Z</dc:date>
    </item>
  </channel>
</rss>

