<?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: Proc Gchart: Pie error in Graphics Programming</title>
    <link>https://communities.sas.com/t5/Graphics-Programming/Proc-Gchart-Pie-error/m-p/103835#M3864</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Since you have pre-calculated your percents in the data set, you could just let gchart sum up those pre-calculated values in the pie slices:&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;proc gchart data=cars;&lt;/P&gt;&lt;P&gt;pie make / type=sum sumvar=percent other=5 noheader;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Courier New;"&gt;&lt;IMG alt="foo.png" class="jive-image-thumbnail jive-image" height="472" src="https://communities.sas.com/legacyfs/online/4329_foo.png" width="635" /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 07 Oct 2013 13:07:33 GMT</pubDate>
    <dc:creator>GraphGuy</dc:creator>
    <dc:date>2013-10-07T13:07:33Z</dc:date>
    <item>
      <title>Proc Gchart: Pie error</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-Gchart-Pie-error/m-p/103832#M3861</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I just spotted an error, which I don't know how to solve programmatically. I have the frequency table below and I wanted to create a pie for the major 5 car manufacturers and group the rest in the category named "other." I used the other=5 option but the resulting pie is not correct. The "other" category should be 24% and not 16%. By looking at the log, I realized that SAS ignored any observation that had a relative frequency less than 1%. Do you know why is it doing that? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data cars;&lt;/P&gt;&lt;P&gt;input make $ count percent;&lt;/P&gt;&lt;P&gt;datalines;&lt;/P&gt;&lt;P&gt;PLYMOUTH&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.0530786&lt;/P&gt;&lt;P&gt;SCION&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.0530786&lt;/P&gt;&lt;P&gt;SUBARU&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.0530786&lt;/P&gt;&lt;P&gt;VOLKSWAGEN&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.0530786&lt;/P&gt;&lt;P&gt;INFINITI&amp;nbsp;&amp;nbsp;&amp;nbsp; 2&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.1061571&lt;/P&gt;&lt;P&gt;LINCOLN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.1061571&lt;/P&gt;&lt;P&gt;ISUZU&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 4&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.2123142&lt;/P&gt;&lt;P&gt;OLDSMOBILE&amp;nbsp;&amp;nbsp;&amp;nbsp; 7&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.3715499&lt;/P&gt;&lt;P&gt;GMC&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 14&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.7430998&lt;/P&gt;&lt;P&gt;HONDA&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 14&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.7430998&lt;/P&gt;&lt;P&gt;BUICK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 16&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.8492569&lt;/P&gt;&lt;P&gt;MERCURY&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 19&amp;nbsp;&amp;nbsp;&amp;nbsp; 1.0084926&lt;/P&gt;&lt;P&gt;MITSUBISHI&amp;nbsp;&amp;nbsp;&amp;nbsp; 26&amp;nbsp;&amp;nbsp;&amp;nbsp; 1.3800425&lt;/P&gt;&lt;P&gt;MAZDA&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 28&amp;nbsp;&amp;nbsp;&amp;nbsp; 1.4861996&lt;/P&gt;&lt;P&gt;SUZUKI&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&amp;nbsp;&amp;nbsp;&amp;nbsp; 1.5923567&lt;/P&gt;&lt;P&gt;TOYOTA&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&amp;nbsp;&amp;nbsp;&amp;nbsp; 1.5923567&lt;/P&gt;&lt;P&gt;JEEP&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 38&amp;nbsp;&amp;nbsp;&amp;nbsp; 2.0169851&lt;/P&gt;&lt;P&gt;HYUNDAI&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 47&amp;nbsp;&amp;nbsp;&amp;nbsp; 2.4946921&lt;/P&gt;&lt;P&gt;SATURN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 52&amp;nbsp;&amp;nbsp;&amp;nbsp; 2.7600849&lt;/P&gt;&lt;P&gt;NISSAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 53&amp;nbsp;&amp;nbsp;&amp;nbsp; 2.8131635&lt;/P&gt;&lt;P&gt;KIA&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 60&amp;nbsp;&amp;nbsp;&amp;nbsp; 3.1847134&lt;/P&gt;&lt;P&gt;PONTIAC&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 122&amp;nbsp;&amp;nbsp;&amp;nbsp; 6.4755839&lt;/P&gt;&lt;P&gt;CHRYSLER&amp;nbsp;&amp;nbsp;&amp;nbsp; 261&amp;nbsp;&amp;nbsp;&amp;nbsp; 13.8535032&lt;/P&gt;&lt;P&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 283&amp;nbsp;&amp;nbsp;&amp;nbsp; 15.0212314&lt;/P&gt;&lt;P&gt;DODGE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 320&amp;nbsp;&amp;nbsp;&amp;nbsp; 16.985138&lt;/P&gt;&lt;P&gt;CHEVROLET&amp;nbsp;&amp;nbsp;&amp;nbsp; 452&amp;nbsp;&amp;nbsp;&amp;nbsp; 23.9915074&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ods html;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc gchart data=cars;&lt;/P&gt;&lt;P&gt;pie make / freq=percent other=5;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ods html close;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV class="c"&gt;&lt;P&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Oct 2013 17:56:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-Gchart-Pie-error/m-p/103832#M3861</guid>
      <dc:creator>Greek</dc:creator>
      <dc:date>2013-10-04T17:56:19Z</dc:date>
    </item>
    <item>
      <title>Re: Proc Gchart: Pie error</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-Gchart-Pie-error/m-p/103833#M3862</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;SAS is working as intended.&amp;nbsp; RTFM (bold added):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;H4 class="xis-argument"&gt;FREQ=&lt;SPAN class="xis-userSuppliedValue"&gt;numeric-variable&lt;/SPAN&gt;&lt;/H4&gt;&lt;P&gt;&lt;SPAN class="xis-shortDescription"&gt;specifies a variable whose values weight the contribution of each observation in the computation of the chart statistic. &lt;/SPAN&gt; &lt;SPAN class="xis-paraSimpleFirst"&gt;Each observation is counted the number of times specified by the value of &lt;SPAN class="xis-userSuppliedValue"&gt;numeric-variable&lt;/SPAN&gt; for that observation. If the value of &lt;SPAN class="xis-userSuppliedValue"&gt;numeric-variable&lt;/SPAN&gt; is missing, 0, or negative, the observation is not used in the statistic calculation. &lt;STRONG&gt;Non-integer values of &lt;SPAN class="xis-userSuppliedValue"&gt;numeric-variable&lt;/SPAN&gt; are truncated to integers&lt;/STRONG&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Oct 2013 18:22:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-Gchart-Pie-error/m-p/103833#M3862</guid>
      <dc:creator>Doc_Duke</dc:creator>
      <dc:date>2013-10-04T18:22:54Z</dc:date>
    </item>
    <item>
      <title>Re: Proc Gchart: Pie error</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-Gchart-Pie-error/m-p/103834#M3863</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This revised code probably gets you closer to what you are looking for. Probably will want to clean it up some more but thought this would provide a starting place.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ods html;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc gchart data=cars;&lt;/P&gt;&lt;P&gt;pie make / freq=count other=5 percent=outside ;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ods html close;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EJ&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Oct 2013 18:34:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-Gchart-Pie-error/m-p/103834#M3863</guid>
      <dc:creator>esjackso</dc:creator>
      <dc:date>2013-10-04T18:34:14Z</dc:date>
    </item>
    <item>
      <title>Re: Proc Gchart: Pie error</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Proc-Gchart-Pie-error/m-p/103835#M3864</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Since you have pre-calculated your percents in the data set, you could just let gchart sum up those pre-calculated values in the pie slices:&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;proc gchart data=cars;&lt;/P&gt;&lt;P&gt;pie make / type=sum sumvar=percent other=5 noheader;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: Courier New;"&gt;&lt;IMG alt="foo.png" class="jive-image-thumbnail jive-image" height="472" src="https://communities.sas.com/legacyfs/online/4329_foo.png" width="635" /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Oct 2013 13:07:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Proc-Gchart-Pie-error/m-p/103835#M3864</guid>
      <dc:creator>GraphGuy</dc:creator>
      <dc:date>2013-10-07T13:07:33Z</dc:date>
    </item>
  </channel>
</rss>

