<?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 Re: Nested/Multiple Data Filter Context Box in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54990#M31084</link>
    <description>Thanks Jim! I had come up with something similar. I was trying to find a way to hide/downsize the unselected points but it doesn't look like that's a possibility.&lt;BR /&gt;&lt;BR /&gt;I think I have also arrived at a different way of doing this altogether: by using the "by()" and looping through each ToolID using a separate SendToGroup(). It's a bit more complicated to set up the titles then, but I will post the results once I have it figured out. Hopefully it helps someone in the future as all your posts have done!</description>
    <pubDate>Fri, 13 Apr 2018 19:09:01 GMT</pubDate>
    <dc:creator>ausername</dc:creator>
    <dc:date>2018-04-13T19:09:01Z</dc:date>
    <item>
      <title>Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54915#M31047</link>
      <description>&lt;P&gt;&amp;nbsp;::edit:: Added a comment in the code and included a screenshot to help visualize.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is it possible to do nested filter context boxes or to generate something that effectively does the same thing? Basically I want a set of parent filters that apply to all plots in a report. The reports within that plot need their own particular filters to limit the data they display.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I&amp;nbsp;have an interactive report layed like this:&lt;/P&gt;&lt;P&gt;(1) An H List box divided into two columns.&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; (A) The first column contains a set of filters that apply to anything in the second column.&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; (B) The second column contains a tab box with multiple tabs for different "tool types."&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;(i) Each tab contains an h list box with a column of variabiity charts for each "tool" of a given type. Each column needs its own filter to limit which "tool" it displays.&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; (a) This filter is hard coded based on a list, but the VarCharts need to update based on the filters in (A).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What I am finding is that if I put a where() within the variability chart, it ignores the filters in (A). I then tried nesting filter context boxes, but this doesn't seem to work. The new filters show up, but only the parent-most filter actually does anything.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Logger.JPG" style="width: 512px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/10360i51534C1358CADB86/image-dimensions/512x292?v=v2" width="512" height="292" role="button" title="Logger.JPG" alt="Logger.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I attempted to create a stripped-down/anonymized version of my code, so there may be some typos:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;myRootPath = "C:\Log_Testing\";
myLogPath = myRootPath;
myReportPath = myRootPath || "Report\";
mypath = myRootPath || "Logs\";

// I tools to plot
// format: ToolID
iTools = {"i1", "i5"};

// P tools to plot
// format: ToolID
pTools = {"p1", "p2"};

Set Current Directory( mypath );

mainDt = Open( myLogPath || "Log.jmp" );

Batch Interactive( 1 );  //Batch mode
dt_name = mainDt &amp;lt;&amp;lt; get name();
dt_path = myLogPath;
mainDt &amp;lt;&amp;lt; Clear Select;

filterContextBox = Data Filter Context Box();

spcWin = New Window( dt_name || "_VarCharts", filterContextBox );

filterBox = H List Box(
	mainDt &amp;lt;&amp;lt; Data Filter(
			//Conditional,
		Local,
		Add Filter(
			columns( :WW, :D ),
			Display( :WW, Blocks Display ),
			Display( :D, Blocks Display ), 

		),
		Mode( Select( 0 ), Show( 1 ), Include( 1 ) ), 
	)
);
	
filterContextBox &amp;lt;&amp;lt; Append( filterbox );
filterBox &amp;lt;&amp;lt; Append( tb = Tab Box() );
tb &amp;lt;&amp;lt; Add( "P", hPTab = H List Box() );
tb &amp;lt;&amp;lt; Add( "I", hITab = H List Box() );

numPTools = N Items( pTools );
numITools = N Items( iTools );

//Create P Plots
For( j = 1, j &amp;lt;= numPTools, j++, 
	
	hPTab &amp;lt;&amp;lt; Append( vToolBox = V List Box() );
	
	vToolBox &amp;lt;&amp;lt; Append( toolTab = Outline Box( pTools[j] ) );
	
	ycol = "VariableName";
	parseName = "Variability Chart for " || ycol;
	toolTab &amp;lt;&amp;lt; append(
		NewChart = Variability Chart(
			Y( Column( ycol ) ),
			X( :WW, :D ),
			Max Iter( 100 ),
			Conv Limit( 0.00000001 ),
			Number Integration Abscissas( 128 ),
			Number Function Evals( 65536 ),
			Analysis Type( Name( "Choose best analysis (EMS REML Bayesian)" ) ),
			Connect Cell Means( 1 ),
			Std Dev Chart( 0 ),
			Points Jittered( 0 ),
			AIAG Labels( 0 ),
			Automatic Recalc( 1 ),&lt;BR /&gt;/*If the next line isn't commented out, it ignores the local filter and only uses this one. I need both. */ &lt;BR /&gt; Where( :ToolID == pTools[j] );
			SendToReport(
				Dispatch( {}, "Variability Gauge", OutlineBox, {Set Title( "" )} ),
				Dispatch( {parseName}, "2", ScaleBox( 2 ), {Format( "Fixed Dec", 4, 0 ), Min( 0 )} ),
				Dispatch( {parseName}, "Group Means", StringColBox, {Visibility( "Collapse" )} ),
				Dispatch( {parseName}, "", PlotColBox, {Visibility( "Collapse" )} )
			)
		)
	);
);&lt;/CODE&gt;&amp;nbsp;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 12 Apr 2018 21:02:58 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54915#M31047</guid>
      <dc:creator>ausername</dc:creator>
      <dc:date>2018-04-12T21:02:58Z</dc:date>
    </item>
    <item>
      <title>Re: Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54927#M31048</link>
      <description>&lt;P&gt;I believe I understand what you want.&amp;nbsp; Here is an example, taken directly from the Scripting Index&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;Help==&amp;gt;Scripting Index==&amp;gt;DataFilterSourceBox&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
New Window( "Selection Filter",
	Data Filter Context Box(
		H List Box(
			dfsb =
			Data Filter Source Box(
				Graph Builder(
					Size( 208, 207 ),
					Show Control Panel( 0 ),
					Show Legend( 0 ),
					Variables( X( :age ) ),
					Elements(
						Bar( X, Legend( 3 ) )
					),
					SendToReport(
						Dispatch(
							{},
							"Graph Builder",
							OutlineBox,
							{Set Title( "Filter" )}
						)
					)
				)
			),
			Platform(
				Current Data Table(),
				Bubble Plot(
					X( :weight ),
					Y( :height ),
					Sizes( :age ),
					Title Position( 0, 0 )
				)
			)
		)
	)
);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Based upon your "Clicked On" selections in one graph, it&amp;nbsp;filters another graph&lt;/P&gt;</description>
      <pubDate>Thu, 12 Apr 2018 18:19:30 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54927#M31048</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2018-04-12T18:19:30Z</dc:date>
    </item>
    <item>
      <title>Re: Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54944#M31051</link>
      <description>&lt;P&gt;Thanks Jim! Unless I'm misunderstanding/overlooking something, this is only filtering the second graph based on the first. How do I filter the second graph in addition to the first?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;i.e. I want the second graph filtered based on the first, but in addition, I only want a subset of the data in the first filter.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Effectively what I want is to add "Where( :ToolID == pTools[j] );" to the Variability chart, but if I do this then it completely ignores the Data Filter Source Box (or in my case the local data filter). I actually spent a long time trying to figure out what I was doing wrong with the Data Filter Source Box only to realize it worked once I removed the above "where" line from the Variability Charts.&lt;/P&gt;</description>
      <pubDate>Thu, 12 Apr 2018 19:06:57 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54944#M31051</guid>
      <dc:creator>ausername</dc:creator>
      <dc:date>2018-04-12T19:06:57Z</dc:date>
    </item>
    <item>
      <title>Re: Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54946#M31053</link>
      <description>&lt;P&gt;Here is an example from a Discussion that I had concerning a 2 Level Filter.&amp;nbsp; It is an expansion on the example I provided in my last post.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );

dt = Open( "$SAMPLE_DATA/Big Class.jmp" );

New Window( "Shared Local Filter",

       Data Filter Context Box(

              H List Box(

                     Data Filter Source Box(

                           H List Box(

                   Graph Builder(

                        Size( 208, 207 ),

                        Show Control Panel( 0 ),

                        Show Legend( 0 ),

                        Variables( X( :age ) ),

                        Elements( Bar( X, Legend( 3 ) ) ),

                        SendToReport( Dispatch( {}, "Graph Builder", OutlineBox, {Set Title( "Filter" )} ) )

                    ),

                                    Data Filter Source Box(

                        Graph Builder(

                            Size( 208, 207 ),

                            Show Control Panel( 0 ),

                            Show Legend( 0 ),

                            Variables( X( :sex ) ),

                            Elements( Bar( X, Legend( 3 ) ) ),

                            SendToReport(

                                Dispatch( {}, "Graph Builder", OutlineBox, {Set Title( "Filter" )} )

                            )

                        )

                    )

                )

            ),

                     Platform(

                           Current Data Table(),

                   Bubble Plot( X( :weight ), Y( :height ), Sizes( :age ), Title Position( 0, 0 ) )

           )

       )

    )

);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 12 Apr 2018 19:54:33 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54946#M31053</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2018-04-12T19:54:33Z</dc:date>
    </item>
    <item>
      <title>Re: Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54950#M31056</link>
      <description>&lt;P&gt;Can you apply different sub-filters to different plots with this method? It seems all plots will receive the same filters.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need a single primary filter with a series of independent (invisible) sub-filters applied to different sets of plots. I've updated my original post with a commented-out "where" filter to better convey this.&lt;/P&gt;</description>
      <pubDate>Thu, 12 Apr 2018 20:37:26 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54950#M31056</guid>
      <dc:creator>ausername</dc:creator>
      <dc:date>2018-04-12T20:37:26Z</dc:date>
    </item>
    <item>
      <title>Re: Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54953#M31058</link>
      <description>&lt;P&gt;I can not definatively say yes, but if you look at the structure of the code I provided, I can imagine being able to expand on it to support your structure.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would take the sample, and see if you can make it branch to two different filtering graphs at the second level of filters.&lt;/P&gt;</description>
      <pubDate>Thu, 12 Apr 2018 21:02:57 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54953#M31058</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2018-04-12T21:02:57Z</dc:date>
    </item>
    <item>
      <title>Re: Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54955#M31060</link>
      <description>&lt;P&gt;&lt;SPAN&gt;I guess that's where I'm lost. It seems the Bubble Plot is dependent on all of the source ones. You&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;can in effect&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;place your "&lt;/SPAN&gt;&lt;SPAN&gt;final" plot in a data filter source box itself, but then you will see all of the&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;undesired&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;data, just unselected/grayed out.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 12 Apr 2018 21:14:17 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54955#M31060</guid>
      <dc:creator>ausername</dc:creator>
      <dc:date>2018-04-12T21:14:17Z</dc:date>
    </item>
    <item>
      <title>Re: Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54977#M31077</link>
      <description>&lt;P&gt;&lt;STRIKE&gt;I have been playing with the code, but I haven't been able to get it to work the way you have specified.&amp;nbsp;&amp;nbsp;&lt;/STRIKE&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRIKE&gt;Sorry, maybe another community member has an idea.&lt;/STRIKE&gt;&lt;/P&gt;
&lt;P&gt;Here is an example where there are 2 independent paths taken from a single selection graph.....I think this is close to what you want&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dt &amp;lt;&amp;lt; New Column( "Potential",
	Character,
	"Nominal",
	Set Values(
		{"1", "2", "1", "2", "1", "2", "1", "2", "1", "2", "1", "2", "1", "2", "1", "2", "1", "2", "1", "2", "1", "2", "1", "2", "1", "2",
		"1", "2", "1", "2", "1", "2", "1", "2", "1", "2", "1", "2", "1", "2"}
	)
);

New Window( "Shared Local Filter",
	Data Filter Context Box(
		H List Box(
			Data Filter Source Box(
				H List Box(
					Graph Builder(
						Size( 208, 207 ),
						Show Control Panel( 0 ),
						Show Legend( 0 ),
						Variables( X( :age ) ),
						Elements( Bar( X, Legend( 3 ) ) ),
						SendToReport( Dispatch( {}, "Graph Builder", OutlineBox, {Set Title( "Filter" )} ) )
					), 
					 
					//Data Filter Context Box(
					V List Box(
						Data Filter Source Box(
							H List Box(
								Graph Builder(
									Size( 208, 207 ),
									Show Control Panel( 0 ),
									Show Legend( 0 ),
									Variables( X( :Potential ) ),
									Elements( Bar( X, Legend( 3 ) ) ),
									SendToReport( Dispatch( {}, "Graph Builder", OutlineBox, {Set Title( "Filter" )} ) )
								),
								Platform(
									Current Data Table(),
									Bubble Plot( Y( :weight ), X( :height ), Sizes( :age ), Title Position( 0, 0 ) )
						
								)
							), 

						),
						Data Filter Source Box(
							H List Box(
								Graph Builder(
									Size( 208, 207 ),
									Show Control Panel( 0 ),
									Show Legend( 0 ),
									Variables( X( :sex ) ),
									Elements( Bar( X, Legend( 3 ) ) ),
									SendToReport( Dispatch( {}, "Graph Builder", OutlineBox, {Set Title( "Filter" )} ) )
								), 

								Platform(
									Current Data Table(),
									Bubble Plot( X( :weight ), Y( :height ), Sizes( :age ), Title Position( 0, 0 ) )
								)
							)
						)
					)
					//)
				)
			)
		)
	)
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 13 Apr 2018 14:21:08 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54977#M31077</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2018-04-13T14:21:08Z</dc:date>
    </item>
    <item>
      <title>Re: Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54990#M31084</link>
      <description>Thanks Jim! I had come up with something similar. I was trying to find a way to hide/downsize the unselected points but it doesn't look like that's a possibility.&lt;BR /&gt;&lt;BR /&gt;I think I have also arrived at a different way of doing this altogether: by using the "by()" and looping through each ToolID using a separate SendToGroup(). It's a bit more complicated to set up the titles then, but I will post the results once I have it figured out. Hopefully it helps someone in the future as all your posts have done!</description>
      <pubDate>Fri, 13 Apr 2018 19:09:01 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/54990#M31084</guid>
      <dc:creator>ausername</dc:creator>
      <dc:date>2018-04-13T19:09:01Z</dc:date>
    </item>
    <item>
      <title>Re: Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/55046#M31123</link>
      <description>&lt;P&gt;I've attached two examples of similar layouts to what you describe:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;SFCrimeNestedFilter.jsl demonstrates how to nest the Data Filter Context Box to get a cascading / hierarchical behavior in the filters.&amp;nbsp; This approach works in JMP 10+, though the syntax that I use for the Tab Box is JMP 13+.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;SFCrimeFilterWithWhere.jsl replaces the inner filter with a Where() clause for each report.&amp;nbsp; This type of layout works in JMP 14 but did not work in prior releases.&amp;nbsp; The issue is that the filter is using the full table, while the report is using a subset table.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I hope this helps!&lt;/P&gt;</description>
      <pubDate>Mon, 16 Apr 2018 12:46:06 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/55046#M31123</guid>
      <dc:creator>danschikore</dc:creator>
      <dc:date>2018-04-16T12:46:06Z</dc:date>
    </item>
    <item>
      <title>Re: Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/55110#M31157</link>
      <description>This appears to be exactly what I'm looking for! Thanks so much! So it looks like my mistake was using source boxes at all?</description>
      <pubDate>Mon, 16 Apr 2018 17:23:11 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/55110#M31157</guid>
      <dc:creator>ausername</dc:creator>
      <dc:date>2018-04-16T17:23:11Z</dc:date>
    </item>
    <item>
      <title>Re: Nested/Multiple Data Filter Context Box</title>
      <link>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/55113#M31160</link>
      <description>&lt;P&gt;In Jim's examples, the Data Filter Source Box is exactly what is needed to use one JMP graph to filter another.&amp;nbsp; I did not see a Data Filter Source Box in your original script - I think the main issue was the use of the Where() clause (subset table) with a filter on the parent table.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The Data Filter Source Box is only need to use a platform as a filter, because unlike the built-in Data Filter object we cannot infer what the filter behavior should be.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 17 Apr 2018 11:47:11 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Nested-Multiple-Data-Filter-Context-Box/m-p/55113#M31160</guid>
      <dc:creator>danschikore</dc:creator>
      <dc:date>2018-04-17T11:47:11Z</dc:date>
    </item>
  </channel>
</rss>

