<?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: Plot variables as percentage of another variable in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497791#M132076</link>
    <description>&lt;P&gt;Your code look good. add option "curvelabel"&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sgplot data=Transposed_average_hz;
scatter x=frequency y=col1/curvelabel ;
scatter x=frequency y=col2/curvelabel;
scatter x=frequency y=col3/curvelabel;
scatter x=frequency y=col4/curvelabel;
scatter x=frequency y=col5/curvelabel;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Fri, 21 Sep 2018 12:38:21 GMT</pubDate>
    <dc:creator>Ksharp</dc:creator>
    <dc:date>2018-09-21T12:38:21Z</dc:date>
    <item>
      <title>Plot variables as percentage of another variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497703#M132011</link>
      <description>&lt;P&gt;Hallo everybody,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I´m plotting my data and I would like to show 4 variable as percentage&amp;nbsp;of another variable.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My data:&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="Unbenannt.png" style="width: 596px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/23440i868D55CF916A0581/image-size/large?v=v2&amp;amp;px=999" role="button" title="Unbenannt.png" alt="Unbenannt.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My Code:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sgplot data=Transposed_average_hz;
scatter x=frequency y=col1;
scatter x=frequency y=col2;
scatter x=frequency y=col3;
scatter x=frequency y=col4;
scatter x=frequency y=col5;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What I would like to have (sort of)...&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="ex.png" style="width: 434px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/23441i4F102D1772F42D46/image-dimensions/434x344?v=v2" width="434" height="344" role="button" title="ex.png" alt="ex.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Thank you very much for your help!&lt;/P&gt;</description>
      <pubDate>Fri, 21 Sep 2018 06:52:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497703#M132011</guid>
      <dc:creator>riccardo88</dc:creator>
      <dc:date>2018-09-21T06:52:16Z</dc:date>
    </item>
    <item>
      <title>Re: Plot variables as percentage of another variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497704#M132012</link>
      <description>&lt;P&gt;What four variables do your want to plot? And what variable should they represent percentages of?&lt;/P&gt;</description>
      <pubDate>Fri, 21 Sep 2018 06:54:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497704#M132012</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2018-09-21T06:54:10Z</dc:date>
    </item>
    <item>
      <title>Re: Plot variables as percentage of another variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497705#M132013</link>
      <description>&lt;P&gt;COL 2,3,4,5 as percentage of COL1.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;COL1 should be a straight line in the graphic.&lt;/P&gt;</description>
      <pubDate>Fri, 21 Sep 2018 06:56:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497705#M132013</guid>
      <dc:creator>riccardo88</dc:creator>
      <dc:date>2018-09-21T06:56:07Z</dc:date>
    </item>
    <item>
      <title>Re: Plot variables as percentage of another variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497708#M132015</link>
      <description>&lt;P&gt;Ok. Can you post your data in a usable form (Not a picture)?&lt;/P&gt;</description>
      <pubDate>Fri, 21 Sep 2018 07:02:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497708#M132015</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2018-09-21T07:02:05Z</dc:date>
    </item>
    <item>
      <title>Re: Plot variables as percentage of another variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497710#M132017</link>
      <description>&lt;P&gt;Looks like Excel thinking again.&amp;nbsp; Get your data looking like:&lt;BR /&gt;COL&amp;nbsp; &amp;nbsp; PCENT&amp;nbsp; &amp;nbsp;FREQUENCY&lt;/P&gt;
&lt;P&gt;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;...&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;...&lt;/P&gt;
&lt;P&gt;....&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then use:&lt;/P&gt;
&lt;PRE class=" language-sas"&gt;&lt;CODE class="  language-sas"&gt;&lt;SPAN class="token procnames"&gt;proc&lt;/SPAN&gt; &lt;SPAN class="token procnames"&gt;sgplot&lt;/SPAN&gt; &lt;SPAN class="token procnames"&gt;data&lt;/SPAN&gt;&lt;SPAN class="token operator"&gt;=&lt;/SPAN&gt;Transposed_average_hz&lt;SPAN class="token punctuation"&gt;;&lt;/SPAN&gt;
  series x&lt;SPAN class="token operator"&gt;=&lt;/SPAN&gt;frequency y&lt;SPAN class="token operator"&gt;=pcent&lt;/SPAN&gt; / group=col&lt;SPAN class="token punctuation"&gt;;&lt;BR /&gt;run;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Note, as you said you want a line, then series is most likely.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 21 Sep 2018 07:06:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497710#M132017</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-09-21T07:06:15Z</dc:date>
    </item>
    <item>
      <title>Re: Plot variables as percentage of another variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497791#M132076</link>
      <description>&lt;P&gt;Your code look good. add option "curvelabel"&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sgplot data=Transposed_average_hz;
scatter x=frequency y=col1/curvelabel ;
scatter x=frequency y=col2/curvelabel;
scatter x=frequency y=col3/curvelabel;
scatter x=frequency y=col4/curvelabel;
scatter x=frequency y=col5/curvelabel;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 21 Sep 2018 12:38:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497791#M132076</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2018-09-21T12:38:21Z</dc:date>
    </item>
    <item>
      <title>Re: Plot variables as percentage of another variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497799#M132080</link>
      <description>&lt;P&gt;Sort by the X variable and use the SERIES statement:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sort data=Transposed_average_hz;
by frequency;
run;

proc sgplot data=Transposed_average_hz;
series x=frequency y=col1 / curvelabel;
series x=frequency y=col2 / curvelabel;
series x=frequency y=col3 / curvelabel;
series x=frequency y=col4 / curvelabel;
series x=frequency y=col5 / curvelabel;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 21 Sep 2018 12:57:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Plot-variables-as-percentage-of-another-variable/m-p/497799#M132080</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2018-09-21T12:57:37Z</dc:date>
    </item>
  </channel>
</rss>

