<?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: gchart: controlling hbar order in Graphics Programming</title>
    <link>https://communities.sas.com/t5/Graphics-Programming/gchart-controlling-hbar-order/m-p/46905#M1595</link>
    <description>I assume you're wanting the bars to be in the same order as your "proc sort" produced?  (and assuming that your data has 1 obsn per each "bu" ... ie, not having gchart summarize several obsns per each "bu")...&lt;BR /&gt;
&lt;BR /&gt;
If so, then you can use hbar's "ascending" (or descending) option to control the bar order.&lt;BR /&gt;
&lt;BR /&gt;
If you wanted the bars to be in some other order (not ascending/descending based on the bar height values), then you would need to get a little trickier, and create a variable that has values of the desired order, and then use a user-defined-format such that that order value will 'print' as the desired "bu" value. (but sounds like you won't need to go to this extra level of complexity).</description>
    <pubDate>Mon, 12 Jul 2010 12:53:40 GMT</pubDate>
    <dc:creator>GraphGuy</dc:creator>
    <dc:date>2010-07-12T12:53:40Z</dc:date>
    <item>
      <title>gchart: controlling hbar order</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/gchart-controlling-hbar-order/m-p/46904#M1594</link>
      <description>How do I maintain the order the variable bu is displayed in my data (ie goals)?&lt;BR /&gt;
&lt;BR /&gt;
proc sort data=goals;by rate;run;&lt;BR /&gt;
&lt;BR /&gt;
axis3 label=("Count") value=(h=2);&lt;BR /&gt;
proc gchart data=goals anno=cbackanno;&lt;BR /&gt;
	hbar bu / &lt;BR /&gt;
	discrete&lt;BR /&gt;
	sumvar=rate</description>
      <pubDate>Fri, 09 Jul 2010 22:24:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/gchart-controlling-hbar-order/m-p/46904#M1594</guid>
      <dc:creator>gzr2mz39</dc:creator>
      <dc:date>2010-07-09T22:24:41Z</dc:date>
    </item>
    <item>
      <title>Re: gchart: controlling hbar order</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/gchart-controlling-hbar-order/m-p/46905#M1595</link>
      <description>I assume you're wanting the bars to be in the same order as your "proc sort" produced?  (and assuming that your data has 1 obsn per each "bu" ... ie, not having gchart summarize several obsns per each "bu")...&lt;BR /&gt;
&lt;BR /&gt;
If so, then you can use hbar's "ascending" (or descending) option to control the bar order.&lt;BR /&gt;
&lt;BR /&gt;
If you wanted the bars to be in some other order (not ascending/descending based on the bar height values), then you would need to get a little trickier, and create a variable that has values of the desired order, and then use a user-defined-format such that that order value will 'print' as the desired "bu" value. (but sounds like you won't need to go to this extra level of complexity).</description>
      <pubDate>Mon, 12 Jul 2010 12:53:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/gchart-controlling-hbar-order/m-p/46905#M1595</guid>
      <dc:creator>GraphGuy</dc:creator>
      <dc:date>2010-07-12T12:53:40Z</dc:date>
    </item>
    <item>
      <title>Re: gchart: controlling hbar order</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/gchart-controlling-hbar-order/m-p/46906#M1596</link>
      <description>If you are using SAS 9.2, you have another alternative. You can use the the SGPLOT procedure to create data-order bar charts:&lt;BR /&gt;
&lt;BR /&gt;
[pre]&lt;BR /&gt;
proc sort data=goals;by rate;run;&lt;BR /&gt;
&lt;BR /&gt;
proc sgplot data=goals;&lt;BR /&gt;
yaxis discreteorder=data;&lt;BR /&gt;
hbar bu / response=rate;&lt;BR /&gt;
run;&lt;BR /&gt;
[/pre]</description>
      <pubDate>Mon, 12 Jul 2010 13:50:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/gchart-controlling-hbar-order/m-p/46906#M1596</guid>
      <dc:creator>DanH_sas</dc:creator>
      <dc:date>2010-07-12T13:50:12Z</dc:date>
    </item>
    <item>
      <title>Re: gchart: controlling hbar order</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/gchart-controlling-hbar-order/m-p/46907#M1597</link>
      <description>hbar's "ascending" worked well.&lt;BR /&gt;
Thanks.</description>
      <pubDate>Mon, 12 Jul 2010 17:29:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/gchart-controlling-hbar-order/m-p/46907#M1597</guid>
      <dc:creator>gzr2mz39</dc:creator>
      <dc:date>2010-07-12T17:29:45Z</dc:date>
    </item>
    <item>
      <title>Re: gchart: controlling hbar order</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/gchart-controlling-hbar-order/m-p/46908#M1598</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; thanks DanH, i was looking for your answer a long time&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Apr 2012 12:58:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/gchart-controlling-hbar-order/m-p/46908#M1598</guid>
      <dc:creator>Filipvdr</dc:creator>
      <dc:date>2012-04-02T12:58:11Z</dc:date>
    </item>
  </channel>
</rss>

