<?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: Is there is way to automatically draw ref lines at the peak of my curve in a plot? in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/87710#M38704</link>
    <description>&lt;P&gt;Correction-&amp;nbsp;&lt;SPAN&gt;How do I darw a line at the peak of the curve without manually seraching for the peak?&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 03 Jan 2019 20:39:56 GMT</pubDate>
    <dc:creator>yfu23</dc:creator>
    <dc:date>2019-01-03T20:39:56Z</dc:date>
    <item>
      <title>Is there a way to automatically draw ref lines at the peak of curve in a plot?</title>
      <link>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/87709#M38703</link>
      <description>&lt;P&gt;How do I darw a line at the peak of the curve without manually seraching for the peak?&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="Untitled.jpg" style="width: 368px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/14993iD372CCD57AA30FE3/image-size/large?v=v2&amp;amp;px=999" role="button" title="Untitled.jpg" alt="Untitled.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 03 Jan 2019 20:40:41 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/87709#M38703</guid>
      <dc:creator>yfu23</dc:creator>
      <dc:date>2019-01-03T20:40:41Z</dc:date>
    </item>
    <item>
      <title>Re: Is there is way to automatically draw ref lines at the peak of my curve in a plot?</title>
      <link>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/87710#M38704</link>
      <description>&lt;P&gt;Correction-&amp;nbsp;&lt;SPAN&gt;How do I darw a line at the peak of the curve without manually seraching for the peak?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 03 Jan 2019 20:39:56 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/87710#M38704</guid>
      <dc:creator>yfu23</dc:creator>
      <dc:date>2019-01-03T20:39:56Z</dc:date>
    </item>
    <item>
      <title>Re: Is there is way to automatically draw ref lines at the peak of my curve in a plot?</title>
      <link>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/87721#M38710</link>
      <description>&lt;P&gt;You can determine the peak by finding the Max value for each group, then find the X value by finding the row that the Max value is found.&lt;/P&gt;
&lt;P&gt;Here is an example of the output and the simple script that creates the reference lines.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="reflines.PNG" style="width: 577px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/14998i4D20A2CCC7FD3B0B/image-dimensions/577x379?v=v2" width="577" height="379" role="button" title="reflines.PNG" alt="reflines.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;and here is the script&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
dt = New Table( "Example",
	Add Rows( 130 ),
	New Script( "Source", Data Table( "Untitled 25" ) &amp;lt;&amp;lt; Sort( By( :Group, :Y ), Order ) ),
	New Column( "Group",
		Numeric,
		"Ordinal",
		Format( "Best", 12 ),
		Set Values(
			[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3,
			3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6,
			6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9,
			9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11,
			11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13,
			13, 13]
		)
	),
	New Column( "Y",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Set Values(
			[1, 2, 3, 6, 7, 7, 8, 8, 8, 10, 1, 2, 2, 3, 5, 5, 6, 7, 8, 10, 1, 3, 3, 5, 6, 7, 8,
			10, 10, 10, 2, 3, 3, 3, 4, 4, 7, 9, 9, 9, 1, 1, 2, 3, 6, 6, 7, 8, 8, 10, 1, 1, 3, 3,
			3, 4, 6, 6, 8, 8, 2, 3, 4, 5, 5, 7, 9, 9, 10, 10, 2, 2, 2, 4, 5, 6, 7, 9, 10, 10, 1,
			1, 2, 3, 3, 4, 8, 9, 9, 10, 1, 3, 3, 4, 4, 4, 4, 7, 8, 10, 2, 3, 4, 5, 6, 7, 8, 8, 8,
			9, 2, 5, 5, 6, 7, 8, 8, 9, 10, 10, 2, 3, 4, 4, 6, 6, 8, 8, 9, 9]
		)
	),
	New Column( "X",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Set Values(
			[1, 2, 3, 4, 5, 6, 10, 9, 7, 8, 1, 2, 3, 4, 5, 6, 10, 9, 7, 8, 1, 2, 3, 4, 5, 6, 10,
			9, 7, 8, 1, 2, 3, 4, 5, 6, 10, 9, 7, 8, 1, 2, 3, 4, 5, 6, 10, 9, 7, 8, 1, 2, 3, 4, 5,
			6, 10, 9, 7, 8, 1, 2, 3, 4, 5, 6, 10, 9, 7, 8, 1, 2, 3, 4, 5, 6, 10, 9, 7, 8, 1, 2,
			3, 4, 5, 6, 10, 9, 7, 8, 1, 2, 3, 4, 5, 6, 10, 9, 7, 8, 1, 2, 3, 4, 5, 6, 10, 9, 7,
			8, 1, 2, 3, 4, 5, 6, 10, 9, 7, 8, 1, 2, 3, 4, 5, 6, 10, 9, 7, 8]
		)
	)
);

// Create the graph
gb = Graph Builder(
	Variables( X( :X ), Y( :Y ), Overlay( :Group ) ),
	Elements( Points( X, Y, Legend( 9 ) ), Line( X, Y, Legend( 11 ) ) )
);

// Find the number of groups and their max
Summarize( dt, bygroup = by( :group ), theYMax = Max( :Y ) );

// Loop across the groups and create reference lines for the max Y found in each group
For( i = 1, i &amp;lt;= N Items( bygroup ), i++,
	theXMax = dt:X[(dt &amp;lt;&amp;lt; get rows where( :group == Num( bygroup[i] ) &amp;amp; :Y == theMax[i] ))[1]];
	Eval(
		Substitute(
				Expr(
					Report( gb )[AxisBox( 1 )] &amp;lt;&amp;lt; add ref line( __x__ );
					Report( gb )[AxisBox( 2 )] &amp;lt;&amp;lt; add ref line( __y__ );
				),
			Expr( __x__ ), theXMax,
			Expr( __y__ ), theYMax[i]
		),

	);
);
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 03 Jan 2019 23:11:05 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/87721#M38710</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2019-01-03T23:11:05Z</dc:date>
    </item>
    <item>
      <title>Re: Is there is way to automatically draw ref lines at the peak of my curve in a plot?</title>
      <link>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/88025#M38725</link>
      <description>&lt;P&gt;&lt;A href="https://community.jmp.com/t5/JSL-Cookbook/Use-Summary-to-Automatically-Add-Reference-Lines-to-Graph/ta-p/41709" target="_self"&gt;https://community.jmp.com/t5/JSL-Cookbook/Use-Summary-to-Automatically-Add-Reference-Lines-to-Graph/ta-p/41709&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 04 Jan 2019 11:27:55 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/88025#M38725</guid>
      <dc:creator>Craige_Hales</dc:creator>
      <dc:date>2019-01-04T11:27:55Z</dc:date>
    </item>
    <item>
      <title>Re: Is there is way to automatically draw ref lines at the peak of my curve in a plot?</title>
      <link>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/91045#M38743</link>
      <description>&lt;P&gt;I don't actually see the ref lines drawn. But I get the idea to use summary to find min, max, mean, etc.&lt;/P&gt;&lt;P&gt;I am using JMP12 and making babe steps.&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="Untitled.jpg" style="width: 999px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/15009i6E161E414728BE6C/image-size/large?v=v2&amp;amp;px=999" role="button" title="Untitled.jpg" alt="Untitled.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 04 Jan 2019 16:11:55 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/91045#M38743</guid>
      <dc:creator>yfu23</dc:creator>
      <dc:date>2019-01-04T16:11:55Z</dc:date>
    </item>
    <item>
      <title>Re: Is there is way to automatically draw ref lines at the peak of my curve in a plot?</title>
      <link>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/91054#M38744</link>
      <description>&lt;P&gt;When I have multiple overlay plots in a report. How do I individually extract data table from each plot?&lt;/P&gt;</description>
      <pubDate>Fri, 04 Jan 2019 16:14:44 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/91054#M38744</guid>
      <dc:creator>yfu23</dc:creator>
      <dc:date>2019-01-04T16:14:44Z</dc:date>
    </item>
    <item>
      <title>Re: Is there is way to automatically draw ref lines at the peak of my curve in a plot?</title>
      <link>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/92540#M38759</link>
      <description>&lt;P&gt;Check the log window, the message suggests this needs a tweak:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;theXMax = dt:X[(dt &amp;lt;&amp;lt; get rows where( :group == Num( bygroup[i] ) &amp;amp; :Y == &lt;EM&gt;&lt;STRONG&gt;theYMax&lt;/STRONG&gt;&lt;/EM&gt;[i] ))[1]];&lt;/P&gt;</description>
      <pubDate>Fri, 04 Jan 2019 20:28:58 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Is-there-a-way-to-automatically-draw-ref-lines-at-the-peak-of/m-p/92540#M38759</guid>
      <dc:creator>Craige_Hales</dc:creator>
      <dc:date>2019-01-04T20:28:58Z</dc:date>
    </item>
  </channel>
</rss>

