<?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 xaxistable in Graphics Programming</title>
    <link>https://communities.sas.com/t5/Graphics-Programming/xaxistable/m-p/835141#M23174</link>
    <description>&lt;P&gt;Hello all,&amp;nbsp;&lt;/P&gt;&lt;P&gt;i am creating a really simple sgplot, where i want to use an xaxistable. My problem is, that the xaxistable is not aligned with the x-axis. It shows too many observations.&amp;nbsp;&lt;/P&gt;&lt;P&gt;How can i get the values to align with the values on the x-axis?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;example data:&lt;/P&gt;&lt;P&gt;data have;&lt;/P&gt;&lt;P&gt;input time count cumulative_percent;&lt;/P&gt;&lt;P&gt;datalines;&lt;/P&gt;&lt;P&gt;1 4 10&lt;/P&gt;&lt;P&gt;2 10 25&lt;/P&gt;&lt;P&gt;3 2 5&lt;/P&gt;&lt;P&gt;4 20 50&lt;/P&gt;&lt;P&gt;5 4 10&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=""&gt;proc sgplot data = abc;
series x=time y = count;
taxis values = 0 to 52 by 5);
xaxistable cumulative_percent;run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="lone0708_0-1664192988684.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/75562i4DCD58F46CF63D8B/image-size/medium?v=v2&amp;amp;px=400" role="button" title="lone0708_0-1664192988684.png" alt="lone0708_0-1664192988684.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 26 Sep 2022 11:54:33 GMT</pubDate>
    <dc:creator>lone0708</dc:creator>
    <dc:date>2022-09-26T11:54:33Z</dc:date>
    <item>
      <title>xaxistable</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/xaxistable/m-p/835141#M23174</link>
      <description>&lt;P&gt;Hello all,&amp;nbsp;&lt;/P&gt;&lt;P&gt;i am creating a really simple sgplot, where i want to use an xaxistable. My problem is, that the xaxistable is not aligned with the x-axis. It shows too many observations.&amp;nbsp;&lt;/P&gt;&lt;P&gt;How can i get the values to align with the values on the x-axis?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;example data:&lt;/P&gt;&lt;P&gt;data have;&lt;/P&gt;&lt;P&gt;input time count cumulative_percent;&lt;/P&gt;&lt;P&gt;datalines;&lt;/P&gt;&lt;P&gt;1 4 10&lt;/P&gt;&lt;P&gt;2 10 25&lt;/P&gt;&lt;P&gt;3 2 5&lt;/P&gt;&lt;P&gt;4 20 50&lt;/P&gt;&lt;P&gt;5 4 10&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=""&gt;proc sgplot data = abc;
series x=time y = count;
taxis values = 0 to 52 by 5);
xaxistable cumulative_percent;run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="lone0708_0-1664192988684.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/75562i4DCD58F46CF63D8B/image-size/medium?v=v2&amp;amp;px=400" role="button" title="lone0708_0-1664192988684.png" alt="lone0708_0-1664192988684.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 26 Sep 2022 11:54:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/xaxistable/m-p/835141#M23174</guid>
      <dc:creator>lone0708</dc:creator>
      <dc:date>2022-09-26T11:54:33Z</dc:date>
    </item>
    <item>
      <title>Re: xaxistable</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/xaxistable/m-p/835153#M23175</link>
      <description>&lt;PRE&gt;data have;
input time count cumulative_percent;
datalines;
1 4 10
2 10 25
3 2 5
4 20 50
5 4 10
;
run;

proc sgplot data = have;
series x=time y = count;
*xaxis values =( 0 to 52 by 5);
xaxistable cumulative_percent/x=time;
run;
&lt;/PRE&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="Ksharp_0-1664196839438.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/75564i38650D8CE0DD57C1/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Ksharp_0-1664196839438.png" alt="Ksharp_0-1664196839438.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 26 Sep 2022 12:53:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/xaxistable/m-p/835153#M23175</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2022-09-26T12:53:43Z</dc:date>
    </item>
    <item>
      <title>Re: xaxistable</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/xaxistable/m-p/835154#M23176</link>
      <description>&lt;P&gt;Thank you for your answer,&amp;nbsp;&lt;/P&gt;&lt;P&gt;When i add the / x=time to my code, i still have way to many datapoints at my graph.&amp;nbsp;&lt;BR /&gt;I have calculated the cumulative percent for each observation, but on my x-axis i have chosen only to show by 5. Can i get the xaxistable to only show by 5 as well?&lt;/P&gt;</description>
      <pubDate>Mon, 26 Sep 2022 12:58:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/xaxistable/m-p/835154#M23176</guid>
      <dc:creator>lone0708</dc:creator>
      <dc:date>2022-09-26T12:58:12Z</dc:date>
    </item>
    <item>
      <title>Re: xaxistable</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/xaxistable/m-p/835164#M23177</link>
      <description>&lt;P&gt;You might need to create a temporary dataset where those unwanted values are set to missing.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Example:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;/* Create sample data for demonstration */

data have;
do time=0 to 52;
  count=round(pdf('chisq',time,3)*1e4+108.9);
  cumulative_percent+count/150;
  output;
end;
label time='use_in_weeks';
run;

/* Restrict values for x-axis table to tick marks */

data want;
set have;
if mod(time,5) then cumulative_percent=.;
format cumulative_percent 5.1;
run;

/* Create the plot with blanks between the x-axis table items */

options missing=' ';
proc sgplot data = want;
series x=time y = count;
xaxis values = (0 to 52 by 5);
xaxistable cumulative_percent / label='cumul. %';
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 26 Sep 2022 13:29:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/xaxistable/m-p/835164#M23177</guid>
      <dc:creator>FreelanceReinh</dc:creator>
      <dc:date>2022-09-26T13:29:36Z</dc:date>
    </item>
  </channel>
</rss>

