<?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: How to script a graph with optional variables? in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-to-script-a-graph-with-optional-variables/m-p/882657#M104673</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/2581"&gt;@miguello&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Might be worth looking a&amp;nbsp;&lt;A href="https://community.jmp.com/t5/JSL-Cookbook/Run-a-Platform-without-Knowing-the-Number-or-Names-of-Columns/ta-p/464407" target="_self"&gt;this post in the JSL cookbook&amp;nbsp;&lt;/A&gt;it focuses on how to run platforms when the number or names of columns can change.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Ben&lt;/P&gt;</description>
    <pubDate>Tue, 01 Jul 2025 15:47:38 GMT</pubDate>
    <dc:creator>Ben_BarrIngh</dc:creator>
    <dc:date>2025-07-01T15:47:38Z</dc:date>
    <item>
      <title>How to script a graph with optional variables?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-script-a-graph-with-optional-variables/m-p/882492#M104647</link>
      <description>&lt;P&gt;Let's say I need to script a graph. And I have a variable that is optional. I might have it, might not have it. Let's say in the example below I might have "Y_Parameter_Std" in the table, might not have it.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;How do I script this optional variable?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;	gb = Graph Builder(
		Size( 350, 200 ),
		Show Control Panel( 0 ),
		Variables( X( Column( X_Parameter ) ), Y( Column( Y_Parameter ) ), Overlay( :Wafer ID ), Interval( Column(Y_Parameter_Std) ) ),
		Elements(
			Points( X, Y, Legend( 14 ), Interval Style( "Band" ) ),
			Smoother( X, Y, Legend( 15 ), Lambda( 0.1 ) ), 
		
		)
	);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;The way I'm going to try it is this:&lt;/P&gt;
&lt;P&gt;Have script for the GB in an expression variable with a placeholder for Interval. If there is a column for interval - replace placeholder with the corresponding expression. If not - replace it with "".&lt;/P&gt;
&lt;P&gt;Any other more elegant way?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;M&lt;/P&gt;</description>
      <pubDate>Mon, 30 Jun 2025 23:58:41 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-script-a-graph-with-optional-variables/m-p/882492#M104647</guid>
      <dc:creator>miguello</dc:creator>
      <dc:date>2025-06-30T23:58:41Z</dc:date>
    </item>
    <item>
      <title>Re: How to script a graph with optional variables?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-script-a-graph-with-optional-variables/m-p/882555#M104654</link>
      <description>&lt;P&gt;In simple cases it is easiest to just use if-statement and two separate graph builder messages&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jul 2025 05:32:20 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-script-a-graph-with-optional-variables/m-p/882555#M104654</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2025-07-01T05:32:20Z</dc:date>
    </item>
    <item>
      <title>Re: How to script a graph with optional variables?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-script-a-graph-with-optional-variables/m-p/882656#M104672</link>
      <description>&lt;P&gt;Well, I have to feed column names into the GB expression anyways, they are not hardcoded, so might as well work on this too.&lt;/P&gt;
&lt;P&gt;Just wondering which of the ways of dealing with expressions is the best.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I remember there was a post on them, maybe even by you, Jarmo, on common ways?&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jul 2025 15:41:36 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-script-a-graph-with-optional-variables/m-p/882656#M104672</guid>
      <dc:creator>miguello</dc:creator>
      <dc:date>2025-07-01T15:41:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to script a graph with optional variables?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-script-a-graph-with-optional-variables/m-p/882657#M104673</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/2581"&gt;@miguello&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Might be worth looking a&amp;nbsp;&lt;A href="https://community.jmp.com/t5/JSL-Cookbook/Run-a-Platform-without-Knowing-the-Number-or-Names-of-Columns/ta-p/464407" target="_self"&gt;this post in the JSL cookbook&amp;nbsp;&lt;/A&gt;it focuses on how to run platforms when the number or names of columns can change.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Ben&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jul 2025 15:47:38 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-script-a-graph-with-optional-variables/m-p/882657#M104673</guid>
      <dc:creator>Ben_BarrIngh</dc:creator>
      <dc:date>2025-07-01T15:47:38Z</dc:date>
    </item>
    <item>
      <title>Re: How to script a graph with optional variables?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-script-a-graph-with-optional-variables/m-p/882727#M104688</link>
      <description>&lt;P&gt;I have demonstrated them few times in community (if you manage to find the posts, not easy with community search), there is one related topic in scripters club and there are more posts also in community.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;LI-MESSAGE title="Scripters Club Recording: JSL in Graph Builder" uid="800152" url="https://community.jmp.com/t5/JMP-Scripters-Club-Discussions/Scripters-Club-Recording-JSL-in-Graph-Builder/m-p/800152#U800152" 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;&lt;/P&gt;
&lt;P&gt;&lt;LI-MESSAGE title="Reply All: How to script dynamic content for Graph Builder" uid="21092" url="https://community.jmp.com/t5/The-Plot-Thickens/Reply-All-How-to-script-dynamic-content-for-Graph-Builder/m-p/21092#U21092" discussion_style_icon_css="lia-mention-container-editor-message lia-img-icon-blog-thread lia-fa-icon lia-fa-blog lia-fa-thread lia-fa"&gt;&lt;/LI-MESSAGE&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;LI-MESSAGE title="How do I use jsl add X variable to graphbuilder" uid="730386" url="https://community.jmp.com/t5/Discussions/How-do-I-use-jsl-add-X-variable-to-graphbuilder/m-p/730386#U730386" 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;&lt;/P&gt;
&lt;P&gt;&lt;LI-MESSAGE title="Graph builder element loop function" uid="848462" url="https://community.jmp.com/t5/Discussions/Graph-builder-element-loop-function/m-p/848462#U848462" 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;&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jul 2025 19:57:21 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-script-a-graph-with-optional-variables/m-p/882727#M104688</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2025-07-01T19:57:21Z</dc:date>
    </item>
  </channel>
</rss>

