<?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: 2 series with group, how to control markers and linestyple in Graphics Programming</title>
    <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628319#M19524</link>
    <description>&lt;P&gt;proc gplot is easy to have plot and plot2 to create two y axes&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am using 9.3.&lt;/P&gt;
&lt;P&gt;switch to use sgplot.&amp;nbsp; 2 series used different color and symbols... can you force to use same color and symbols ?&lt;/P&gt;
&lt;P&gt;I tried goptions colors=(...) and not help.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;this is what I have&lt;/P&gt;
&lt;P&gt;proc sgplot data=stat ; &lt;BR /&gt;series y=iron x=atptn /group=trt name='iron' lineattrs=(pattern=solid) markers ; &lt;BR /&gt;series y=fer x=atptn /y2axis group=trt name='fer' lineattrs=(pattern=dash) markers;&lt;BR /&gt;xaxis label='Hour'; &lt;BR /&gt;yaxis label='Mean Y Concentration (µg/mL)';&lt;BR /&gt;y2axis label='Mean Y2 Concentration (ng/mL)';&amp;nbsp;&lt;BR /&gt;keylegend 'iron' /title='Dose' noborder ;&lt;BR /&gt;run;&lt;/P&gt;</description>
    <pubDate>Fri, 28 Feb 2020 20:22:21 GMT</pubDate>
    <dc:creator>sueshaw</dc:creator>
    <dc:date>2020-02-28T20:22:21Z</dc:date>
    <item>
      <title>sgplot: 2 series with group, how to control markers and linestyple</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628319#M19524</link>
      <description>&lt;P&gt;proc gplot is easy to have plot and plot2 to create two y axes&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am using 9.3.&lt;/P&gt;
&lt;P&gt;switch to use sgplot.&amp;nbsp; 2 series used different color and symbols... can you force to use same color and symbols ?&lt;/P&gt;
&lt;P&gt;I tried goptions colors=(...) and not help.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;this is what I have&lt;/P&gt;
&lt;P&gt;proc sgplot data=stat ; &lt;BR /&gt;series y=iron x=atptn /group=trt name='iron' lineattrs=(pattern=solid) markers ; &lt;BR /&gt;series y=fer x=atptn /y2axis group=trt name='fer' lineattrs=(pattern=dash) markers;&lt;BR /&gt;xaxis label='Hour'; &lt;BR /&gt;yaxis label='Mean Y Concentration (µg/mL)';&lt;BR /&gt;y2axis label='Mean Y2 Concentration (ng/mL)';&amp;nbsp;&lt;BR /&gt;keylegend 'iron' /title='Dose' noborder ;&lt;BR /&gt;run;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Feb 2020 20:22:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628319#M19524</guid>
      <dc:creator>sueshaw</dc:creator>
      <dc:date>2020-02-28T20:22:21Z</dc:date>
    </item>
    <item>
      <title>Re: sgplot: 2 series with group, how to control markers and linestyple</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628334#M19525</link>
      <description>Which exact version of 9.3 are you using? You can check with the following code:&lt;BR /&gt;&lt;BR /&gt;proc product_status;run;&lt;BR /&gt;&lt;BR /&gt;There are several methods of doing this, I prefer data attribute maps because it's pretty straightforward and dynamic but there's also a STYLEATTRS statement that allows you to control the symbols/shapes/colours etc. &lt;BR /&gt;&lt;BR /&gt;GOPTIONS do not apply to SG graphics. &lt;BR /&gt;</description>
      <pubDate>Fri, 28 Feb 2020 20:45:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628334#M19525</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-02-28T20:45:56Z</dc:date>
    </item>
    <item>
      <title>Re: sgplot: 2 series with group, how to control markers and linestyple</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628371#M19526</link>
      <description>&lt;P&gt;thank you so much.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;for sas/graph, 9.3_M2&lt;/P&gt;
&lt;P&gt;log file: SAS (r) Proprietary Software 9.3 (TS1M2)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I tried and got this msg, ERROR 180-322: Statement is not valid or it is used out of proper order.&lt;/P&gt;
&lt;P&gt;maybe this option is not available on my version&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sgplot data=stat ; &lt;BR /&gt;styleattrs datacolors=(red black blue green purple)&lt;BR /&gt;datasymbols=(circle square diamond triangle dot);&lt;BR /&gt;series y=iron x=atptn /group=trt name='iron' lineattrs=(pattern=solid) markers ; &lt;BR /&gt;series y=fer x=atptn /y2axis group=trt name='fer' lineattrs=(pattern=dash) markers;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Feb 2020 23:39:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628371#M19526</guid>
      <dc:creator>sueshaw</dc:creator>
      <dc:date>2020-02-28T23:39:22Z</dc:date>
    </item>
    <item>
      <title>Re: sgplot: 2 series with group, how to control markers and linestyple</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628469#M19528</link>
      <description>&lt;P&gt;It looks like STYLEATTRS is not available for 9.3 M2, but it does look like data attribute maps are supported so that's good news.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here's an example of how to specify your different options.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/grstatproc/65235/HTML/default/viewer.htm#n1sgstxp3pedkxn1tewmmgxccrqh.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/grstatproc/65235/HTML/default/viewer.htm#n1sgstxp3pedkxn1tewmmgxccrqh.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here's the full documentation on attribute maps so you can specify exactly what you want.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/grstatproc/65235/HTML/default/viewer.htm#p0teue0ztycuidn14cciruv038ur.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/grstatproc/65235/HTML/default/viewer.htm#p0teue0ztycuidn14cciruv038ur.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope that helps!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/25606"&gt;@sueshaw&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;thank you so much.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;for sas/graph, 9.3_M2&lt;/P&gt;
&lt;P&gt;log file: SAS (r) Proprietary Software 9.3 (TS1M2)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I tried and got this msg, ERROR 180-322: Statement is not valid or it is used out of proper order.&lt;/P&gt;
&lt;P&gt;maybe this option is not available on my version&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sgplot data=stat ; &lt;BR /&gt;styleattrs datacolors=(red black blue green purple)&lt;BR /&gt;datasymbols=(circle square diamond triangle dot);&lt;BR /&gt;series y=iron x=atptn /group=trt name='iron' lineattrs=(pattern=solid) markers ; &lt;BR /&gt;series y=fer x=atptn /y2axis group=trt name='fer' lineattrs=(pattern=dash) markers;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 29 Feb 2020 19:24:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628469#M19528</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-02-29T19:24:48Z</dc:date>
    </item>
    <item>
      <title>Re: sgplot: 2 series with group, how to control markers and linestyple</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628577#M19533</link>
      <description>&lt;P&gt;Dear Reeza:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I did not get any error msgs, but the output has no impact on the new attribute.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thanks for your help.&lt;/P&gt;</description>
      <pubDate>Sun, 01 Mar 2020 19:44:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628577#M19533</guid>
      <dc:creator>sueshaw</dc:creator>
      <dc:date>2020-03-01T19:44:48Z</dc:date>
    </item>
    <item>
      <title>Re: sgplot: 2 series with group, how to control markers and linestyple</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628586#M19536</link>
      <description>Show your code and output then.</description>
      <pubDate>Sun, 01 Mar 2020 21:42:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628586#M19536</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-03-01T21:42:41Z</dc:date>
    </item>
    <item>
      <title>Re: sgplot: 2 series with group, how to control markers and linestyple</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628642#M19538</link>
      <description>&lt;P&gt;in creating an example for you, I found out dattrmap solved the problem.&lt;/P&gt;
&lt;P&gt;previously, I had a format for group variable...&lt;/P&gt;
&lt;P&gt;once I remove format statement, and use raw data in attrmap and group, it worked.&lt;/P&gt;
&lt;P&gt;this is great.... thank you...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;another quick question... any ways to specify same symbol ?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 Mar 2020 02:23:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628642#M19538</guid>
      <dc:creator>sueshaw</dc:creator>
      <dc:date>2020-03-02T02:23:57Z</dc:date>
    </item>
    <item>
      <title>Re: sgplot: 2 series with group, how to control markers and linestyple</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628827#M19544</link>
      <description>&lt;P&gt;Same idea, add another column with the appropriate name and values and it will ensure the symbols are consistent.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/25606"&gt;@sueshaw&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;in creating an example for you, I found out dattrmap solved the problem.&lt;/P&gt;
&lt;P&gt;previously, I had a format for group variable...&lt;/P&gt;
&lt;P&gt;once I remove format statement, and use raw data in attrmap and group, it worked.&lt;/P&gt;
&lt;P&gt;this is great.... thank you...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;another quick question... any ways to specify same symbol ?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 Mar 2020 16:39:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/628827#M19544</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-03-02T16:39:55Z</dc:date>
    </item>
    <item>
      <title>Re: sgplot: 2 series with group, how to control markers and linestyple</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/629211#M19549</link>
      <description>&lt;P&gt;I did not find document about symbol in SG attribute&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I added a column of markersymbol to dataset attrmap,&lt;/P&gt;
&lt;P&gt;got error msg&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ERROR 772-580: Syntax error: expecting a constant or a dynamic.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I will accept with the solution to specify the color for now.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thank you for all of your help&lt;/P&gt;</description>
      <pubDate>Tue, 03 Mar 2020 18:37:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/629211#M19549</guid>
      <dc:creator>sueshaw</dc:creator>
      <dc:date>2020-03-03T18:37:06Z</dc:date>
    </item>
    <item>
      <title>Re: sgplot: 2 series with group, how to control markers and linestyple</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/629213#M19550</link>
      <description>&lt;P&gt;Do a PROC PRINT of your attrmap data set. You would get that error if the marker symbol name is invalid (misspelled or truncated).&lt;/P&gt;</description>
      <pubDate>Tue, 03 Mar 2020 18:40:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/629213#M19550</guid>
      <dc:creator>DanH_sas</dc:creator>
      <dc:date>2020-03-03T18:40:53Z</dc:date>
    </item>
    <item>
      <title>Re: sgplot: 2 series with group, how to control markers and linestyple</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/629226#M19551</link>
      <description>&lt;P&gt;this is amazing.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I need to increase length for markersymbol.&lt;/P&gt;
&lt;P&gt;I also added markercolor.&lt;/P&gt;
&lt;P&gt;now. the outcome is exactly what I am looking for.&lt;/P&gt;
&lt;P&gt;I have attached the output fyi.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thanks all for the help&lt;/P&gt;</description>
      <pubDate>Tue, 03 Mar 2020 19:21:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/sgplot-2-series-with-group-how-to-control-markers-and-linestyple/m-p/629226#M19551</guid>
      <dc:creator>sueshaw</dc:creator>
      <dc:date>2020-03-03T19:21:47Z</dc:date>
    </item>
  </channel>
</rss>

