<?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: yaxis in sgplot in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/yaxis-in-sgplot/m-p/790551#M253128</link>
    <description>Thanks, Ric. I don't know why it didn't work for me - but it does now! Have a nice day.</description>
    <pubDate>Mon, 17 Jan 2022 17:19:20 GMT</pubDate>
    <dc:creator>madsgregers</dc:creator>
    <dc:date>2022-01-17T17:19:20Z</dc:date>
    <item>
      <title>yaxis in sgplot</title>
      <link>https://communities.sas.com/t5/SAS-Programming/yaxis-in-sgplot/m-p/790521#M253118</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a problem with my y-axis in a sgplot. My code is:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;proc sgplot data=mydata;
   vline informed / response=asked stat=mean limitstat=clm LEGENDLABEL = 'Average [95% CLM]' MARKERS LINEATTRS = (THICKNESS = 2);
run;&lt;/PRE&gt;&lt;P&gt;Can I set the y-axis to a fixed interval? The highest value is 12.5 now, but I would like the y-axis to go up to 20 (despite I do not have any observations here but it is to compare this graph with another one so the y-axis is similar). I tried both the "yaxis min=0 max=20" and "yaxis values=(0 to 20 by 1)".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 17 Jan 2022 13:59:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/yaxis-in-sgplot/m-p/790521#M253118</guid>
      <dc:creator>madsgregers</dc:creator>
      <dc:date>2022-01-17T13:59:26Z</dc:date>
    </item>
    <item>
      <title>Re: yaxis in sgplot</title>
      <link>https://communities.sas.com/t5/SAS-Programming/yaxis-in-sgplot/m-p/790527#M253119</link>
      <description>&lt;P&gt;Both of your ideas should work.&amp;nbsp; There must have been a problem with your implementation. Run the following program and see if it works for you:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data mydata;
call streaminit(1);
do x = 1 to 20;
   do rep = 1 to 10;
      y = 1.5 + abs(x-10) + rand("uniform");
   end;
   output;
end;
run;

proc sgplot data=mydata;
   vline x / response=y stat=mean limitstat=clm LEGENDLABEL = 'Average [95% CLM]' MARKERS LINEATTRS = (THICKNESS = 2);
   yaxis min=0 max=20 ;
run;

proc sgplot data=mydata;
   vline x / response=y stat=mean limitstat=clm LEGENDLABEL = 'Average [95% CLM]' MARKERS LINEATTRS = (THICKNESS = 2);
   yaxis values=(0 to 20 by 1);
run;

&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;span class="lia-inline-image-display-wrapper lia-image-align-left" image-alt="SGPlot1.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/67463i7F8A080B87A68DC2/image-size/medium?v=v2&amp;amp;px=400" role="button" title="SGPlot1.png" alt="SGPlot1.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-left" image-alt="SGPlot.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/67462iB147A7FAD0E6F638/image-size/medium?v=v2&amp;amp;px=400" role="button" title="SGPlot.png" alt="SGPlot.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 17 Jan 2022 14:38:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/yaxis-in-sgplot/m-p/790527#M253119</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2022-01-17T14:38:51Z</dc:date>
    </item>
    <item>
      <title>Re: yaxis in sgplot</title>
      <link>https://communities.sas.com/t5/SAS-Programming/yaxis-in-sgplot/m-p/790551#M253128</link>
      <description>Thanks, Ric. I don't know why it didn't work for me - but it does now! Have a nice day.</description>
      <pubDate>Mon, 17 Jan 2022 17:19:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/yaxis-in-sgplot/m-p/790551#M253128</guid>
      <dc:creator>madsgregers</dc:creator>
      <dc:date>2022-01-17T17:19:20Z</dc:date>
    </item>
  </channel>
</rss>

