<?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 SGPLOT VBOX plot with SCATTER overlay in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/SGPLOT-VBOX-plot-with-SCATTER-overlay/m-p/943857#M369892</link>
    <description>&lt;P&gt;I'm trying to make a boxplot with scatter overlay that includes category and group. Boxplot turns out OK, but scatter is all lumped within category as shown. I can't find a statement for SCATTER that would separate the points by both category and by group.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=""&gt;proc sgplot data=mydata;
	vbox velocity / category=site group=target;
	scatter x=site y=velocity / jitter transparency=0.8 markerattrs=(color=black symbol=circle size=4);
	yaxis type=log;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Vic3_1-1726255388053.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/100309i64F138E5B866545D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Vic3_1-1726255388053.png" alt="Vic3_1-1726255388053.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 13 Sep 2024 19:33:15 GMT</pubDate>
    <dc:creator>Vic3</dc:creator>
    <dc:date>2024-09-13T19:33:15Z</dc:date>
    <item>
      <title>SGPLOT VBOX plot with SCATTER overlay</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SGPLOT-VBOX-plot-with-SCATTER-overlay/m-p/943857#M369892</link>
      <description>&lt;P&gt;I'm trying to make a boxplot with scatter overlay that includes category and group. Boxplot turns out OK, but scatter is all lumped within category as shown. I can't find a statement for SCATTER that would separate the points by both category and by group.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=""&gt;proc sgplot data=mydata;
	vbox velocity / category=site group=target;
	scatter x=site y=velocity / jitter transparency=0.8 markerattrs=(color=black symbol=circle size=4);
	yaxis type=log;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Vic3_1-1726255388053.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/100309i64F138E5B866545D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Vic3_1-1726255388053.png" alt="Vic3_1-1726255388053.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Sep 2024 19:33:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SGPLOT-VBOX-plot-with-SCATTER-overlay/m-p/943857#M369892</guid>
      <dc:creator>Vic3</dc:creator>
      <dc:date>2024-09-13T19:33:15Z</dc:date>
    </item>
    <item>
      <title>Re: SGPLOT VBOX plot with SCATTER overlay</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SGPLOT-VBOX-plot-with-SCATTER-overlay/m-p/943859#M369894</link>
      <description>&lt;P&gt;You need group and&amp;nbsp; groupdisplay=cluster for the scatter plot, and may need to play with clusterwidth as well.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;See this answer:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://communities.sas.com/t5/Graphics-Programming/SAS-proc-sgplot-vbox-scatter-overlay-groups-not-aligned/m-p/832476" target="_blank"&gt;https://communities.sas.com/t5/Graphics-Programming/SAS-proc-sgplot-vbox-scatter-overlay-groups-not-aligned/m-p/832476&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And this blog post:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://blogs.sas.com/content/graphicallyspeaking/2015/12/23/box-plot-with-stat-table-and-markers/" target="_blank"&gt;https://blogs.sas.com/content/graphicallyspeaking/2015/12/23/box-plot-with-stat-table-and-markers/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Sep 2024 20:05:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SGPLOT-VBOX-plot-with-SCATTER-overlay/m-p/943859#M369894</guid>
      <dc:creator>Quentin</dc:creator>
      <dc:date>2024-09-13T20:05:00Z</dc:date>
    </item>
    <item>
      <title>Re: SGPLOT VBOX plot with SCATTER overlay</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SGPLOT-VBOX-plot-with-SCATTER-overlay/m-p/943864#M369897</link>
      <description>Thank you! It solved my problem.&lt;BR /&gt;That blog is excellent.</description>
      <pubDate>Fri, 13 Sep 2024 20:26:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SGPLOT-VBOX-plot-with-SCATTER-overlay/m-p/943864#M369897</guid>
      <dc:creator>Vic3</dc:creator>
      <dc:date>2024-09-13T20:26:47Z</dc:date>
    </item>
    <item>
      <title>Re: SGPLOT VBOX plot with SCATTER overlay</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SGPLOT-VBOX-plot-with-SCATTER-overlay/m-p/943865#M369898</link>
      <description>&lt;P&gt;You might try switching to SGPANEL with your SITE variable as the Panelby variable. Target would then be available as the Category for VBOX and the X variable for the scatter and as the Group variable.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Maybe something like:&lt;/P&gt;
&lt;PRE&gt;proc sgpanel data=mydata;
   panelby site /columns=3;
	vbox velocity / category= target;
	scatter x=target y=velocity / group=target jitter transparency=0.8 
                                markerattrs=( symbol=circle size=4);
	rowaxis type=log;
run;&lt;/PRE&gt;
&lt;P&gt;If this is close there are things that can be done with appearance options to remove dividing lines between panels and such. Do note that using target as group for scatter means you don't want to specify the color for the markers...&lt;/P&gt;</description>
      <pubDate>Fri, 13 Sep 2024 20:28:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SGPLOT-VBOX-plot-with-SCATTER-overlay/m-p/943865#M369898</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2024-09-13T20:28:00Z</dc:date>
    </item>
  </channel>
</rss>

