<?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: Adding mean line by script in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/524169#M74883</link>
    <description>&lt;P&gt;You'll need to provide more information -- How are you adding the line?&amp;nbsp; Can you provide a script that uses an example data table so that we can test?&lt;/P&gt;</description>
    <pubDate>Wed, 20 Jul 2022 23:21:46 GMT</pubDate>
    <dc:creator>ErraticAttack</dc:creator>
    <dc:date>2022-07-20T23:21:46Z</dc:date>
    <item>
      <title>Adding mean line by script</title>
      <link>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/523779#M74847</link>
      <description>&lt;P&gt;I can build a graph and add a horizontal mean line. When I try to extract the script it doesn't reproduce any line.&lt;/P&gt;&lt;P&gt;I have attached the script below&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Graph Builder(
	Size( 1964, 1192 ),
	Variables( X( Column ), Y( Column ), Group X( Column_a ) ),
	Elements( Bar( X, Y, Legend( 11 ) ), Line( Y, Legend( 12 ) ) ),
	Local Data Filter(
		Add Filter( columns( Column_a ), Where( Column &amp;gt;= 0 &amp;amp; Column_a &amp;lt;= 3.2 ) )
	),
	SendToReport(
		Dispatch( {"Line"}, "", OutlineBox, {Close( 0 )} ),
		Dispatch(
			{},
			"400",
			ScaleBox,
			{Legend Model(
				11,
				Properties( 0, {Fill Color( 0 )}, Item ID( "Column", 1 ) )
			)}
		)
	)
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 09 Jun 2023 17:04:49 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/523779#M74847</guid>
      <dc:creator>Jemster</dc:creator>
      <dc:date>2023-06-09T17:04:49Z</dc:date>
    </item>
    <item>
      <title>Re: Adding mean line by script</title>
      <link>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/524169#M74883</link>
      <description>&lt;P&gt;You'll need to provide more information -- How are you adding the line?&amp;nbsp; Can you provide a script that uses an example data table so that we can test?&lt;/P&gt;</description>
      <pubDate>Wed, 20 Jul 2022 23:21:46 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/524169#M74883</guid>
      <dc:creator>ErraticAttack</dc:creator>
      <dc:date>2022-07-20T23:21:46Z</dc:date>
    </item>
    <item>
      <title>Re: Adding mean line by script</title>
      <link>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/524243#M74887</link>
      <description>&lt;P&gt;Here is an example of adding a Line to an existing Graph Builder plot&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="txnelson_0-1658370235569.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/44166iFE5E0C6497C45A77/image-size/medium?v=v2&amp;amp;px=400" role="button" title="txnelson_0-1658370235569.png" alt="txnelson_0-1658370235569.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
gb = Graph Builder(
	Variables( X( :height ), Y( :weight ) ),
	Elements( Points( X, Y ), Smoother( X, Y ) )
);
gbb = Report( gb )[Graph Builder Box( 1 )];
gbb &amp;lt;&amp;lt; Add Element( 1, 1, {Type( "Line" ), X, Y} );&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;The documentation for the messages that can be sent to Graph Builder are found in the Scripting Index.&lt;/P&gt;</description>
      <pubDate>Thu, 21 Jul 2022 02:25:22 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/524243#M74887</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2022-07-21T02:25:22Z</dc:date>
    </item>
    <item>
      <title>Re: Adding mean line by script</title>
      <link>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/524341#M74905</link>
      <description>&lt;P&gt;Thank you, this works to add a line but I was wondering how I can change it so that the line is a horizontal line displaying the mean Y variable&lt;/P&gt;</description>
      <pubDate>Thu, 21 Jul 2022 07:38:48 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/524341#M74905</guid>
      <dc:creator>Jemster</dc:creator>
      <dc:date>2022-07-21T07:38:48Z</dc:date>
    </item>
    <item>
      <title>Re: Adding mean line by script</title>
      <link>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/524357#M74906</link>
      <description>&lt;P&gt;Go to the Scripting Index and search on&lt;/P&gt;
&lt;P&gt;add ref line&lt;/P&gt;</description>
      <pubDate>Thu, 21 Jul 2022 08:06:30 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/524357#M74906</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2022-07-21T08:06:30Z</dc:date>
    </item>
    <item>
      <title>Re: Adding mean line by script</title>
      <link>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/524360#M74907</link>
      <description>&lt;P&gt;I overlayed the two graphs onto one plot by adding the script for the line graph I wanted into the elements section of the script&lt;/P&gt;</description>
      <pubDate>Thu, 21 Jul 2022 08:27:16 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Adding-mean-line-by-script/m-p/524360#M74907</guid>
      <dc:creator>Jemster</dc:creator>
      <dc:date>2022-07-21T08:27:16Z</dc:date>
    </item>
  </channel>
</rss>

