<?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 automate managing limits feature through JSL in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-to-automate-managing-limits-feature-through-JSL/m-p/753601#M93537</link>
    <description>&lt;P&gt;I think one of the examples from Scripting Index should get you almost there&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jthi_0-1715436272959.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/64112i3E6C817829C130A5/image-size/medium?v=v2&amp;amp;px=400" role="button" title="jthi_0-1715436272959.png" alt="jthi_0-1715436272959.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;You just need to add opening your tables, saving of your data table, closing manage limits platform and closing of tables (if needed). Extra things you might want to implement commented out&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);

// dt_limits = Open("...");
// dt_meas = Open("...");

dt_limits = New Table("Cities Limits",
	Add Rows(4),
	New Column("Process",
		Character,
		Set Values({"OZONE", "CO", "SO2", "NO"})
	),
	New Column("LSL", Numeric, Set Values([0, 0, 0, 0])),
	New Column("Target",
		Numeric,
		Set Values([0.2, 15, 0.05, 0.035])
	),
	New Column("USL",
		Numeric,
		Set Values([0.4, 30, 0.1, 0.07])
	),
	Set Label Columns(:Process)
);

dt_meas = Open("$SAMPLE_DATA/Cities.jmp");

ml = dt_meas &amp;lt;&amp;lt; Manage Limits(
	Process Variables(:OZONE, :CO, :SO2, :NO),
	Load From Limits Table(dtLimits)
);

ml &amp;lt;&amp;lt; Save to Column Properties;

// ml &amp;lt;&amp;lt; close window;
// dt_meas &amp;lt;&amp;lt; Save("...");
// Close(dt_limits, no save);
// Close(dt_meas, no save);&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Sat, 11 May 2024 14:06:40 GMT</pubDate>
    <dc:creator>jthi</dc:creator>
    <dc:date>2024-05-11T14:06:40Z</dc:date>
    <item>
      <title>How to automate managing limits feature through JSL</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-automate-managing-limits-feature-through-JSL/m-p/753524#M93529</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to use JSL to perform manage limits. I'm trying to open a limit table, implement it on the current data table and then save it. The only function I found in the fourm or in the scripting index is to open the manage limits and then manually implement the limit or manually open a data table.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The other methods I found was hard-coding the spec limit using JSL.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there are a way I can automate the process through JSL? Assuming I have a limit table and a data table in the same folder.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2024 23:44:44 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-automate-managing-limits-feature-through-JSL/m-p/753524#M93529</guid>
      <dc:creator>RA899</dc:creator>
      <dc:date>2024-05-10T23:44:44Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate managing limits feature through JSL</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-automate-managing-limits-feature-through-JSL/m-p/753601#M93537</link>
      <description>&lt;P&gt;I think one of the examples from Scripting Index should get you almost there&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jthi_0-1715436272959.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/64112i3E6C817829C130A5/image-size/medium?v=v2&amp;amp;px=400" role="button" title="jthi_0-1715436272959.png" alt="jthi_0-1715436272959.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;You just need to add opening your tables, saving of your data table, closing manage limits platform and closing of tables (if needed). Extra things you might want to implement commented out&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);

// dt_limits = Open("...");
// dt_meas = Open("...");

dt_limits = New Table("Cities Limits",
	Add Rows(4),
	New Column("Process",
		Character,
		Set Values({"OZONE", "CO", "SO2", "NO"})
	),
	New Column("LSL", Numeric, Set Values([0, 0, 0, 0])),
	New Column("Target",
		Numeric,
		Set Values([0.2, 15, 0.05, 0.035])
	),
	New Column("USL",
		Numeric,
		Set Values([0.4, 30, 0.1, 0.07])
	),
	Set Label Columns(:Process)
);

dt_meas = Open("$SAMPLE_DATA/Cities.jmp");

ml = dt_meas &amp;lt;&amp;lt; Manage Limits(
	Process Variables(:OZONE, :CO, :SO2, :NO),
	Load From Limits Table(dtLimits)
);

ml &amp;lt;&amp;lt; Save to Column Properties;

// ml &amp;lt;&amp;lt; close window;
// dt_meas &amp;lt;&amp;lt; Save("...");
// Close(dt_limits, no save);
// Close(dt_meas, no save);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 11 May 2024 14:06:40 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-automate-managing-limits-feature-through-JSL/m-p/753601#M93537</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2024-05-11T14:06:40Z</dc:date>
    </item>
  </channel>
</rss>

