<?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: Unable to make a pie of 10 variables across all the States in US in Graphics Programming</title>
    <link>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456187#M15665</link>
    <description>&lt;P&gt;Check your negative values in Means dataset.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/20014iC48F9AFAEB3F7ACF/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 21 Apr 2018 15:09:16 GMT</pubDate>
    <dc:creator>SuryaKiran</dc:creator>
    <dc:date>2018-04-21T15:09:16Z</dc:date>
    <item>
      <title>Unable to make a pie of 10 variables across all the States in US</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456158#M15661</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have been struggling with a data set I have been trying to make a pie chart with the means of 10 variables across all the States in the US. This implies I need 10 pie chart in all, representing the 10 variables.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Below is how I did my coding:&lt;/P&gt;&lt;P&gt;proc means data = final StackODSOutput mean maxdec = 2;&lt;BR /&gt;&amp;nbsp;var &amp;nbsp;No_Exercise Few_Fruit_Veg Obesity&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;High_Blood_Pres Smoker Diabetes&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;Uninsured Elderly_Medicare&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;Prim_Care_Phys_Rate Dentist_Rate;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&lt;BR /&gt;&amp;nbsp;class &amp;nbsp;CHSI_State_Name;&lt;BR /&gt;ods output summary = means;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;proc print data = means(drop = _control_ NOBS);&lt;BR /&gt;run;&lt;BR /&gt;*************;&lt;/P&gt;&lt;P&gt;pattern1 V=S c=vibg;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;pattern2 v=s c=dabg;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;pattern3 v=s c=mob;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;pattern4 v=s c=day;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;pattern5 v=s c=deoy;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;pattern6 v=s c=grp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;pattern7 v=s c=gray;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;pattern8 v=s c=beige;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;pattern9 v=s c=indigo;&lt;BR /&gt;pattern10 v=s c=vliv;&lt;BR /&gt;run;&lt;BR /&gt;&amp;nbsp;&lt;BR /&gt;&amp;nbsp;/* Set the graphics environment */&lt;BR /&gt;goptions reset=all border cback=white&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ctext=black htitle=12pt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;proc gchart data = means;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; pie variable / sumvar = mean group =&amp;nbsp; CHSI_State_Name;&lt;BR /&gt;run;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;quit;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But I keep getting this error message:&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;ERROR: A PIE chart for Variable was not possible because the sum variable Mean had one or more negative values.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Meanwhile I have no negative values.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thanks for your help&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 21 Apr 2018 10:18:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456158#M15661</guid>
      <dc:creator>tarkom</dc:creator>
      <dc:date>2018-04-21T10:18:03Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to make a pie of 10 variables across all the States in US</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456182#M15662</link>
      <description>&lt;P&gt;You didn't show how you created the file FINAL but, if importing the data you attached and running PROC MEANS on it, there are numerous negative values.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Art, CEO, AnalystFinder.com&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 21 Apr 2018 14:39:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456182#M15662</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2018-04-21T14:39:14Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to make a pie of 10 variables across all the States in US</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456183#M15663</link>
      <description>&lt;P&gt;Thank you very much for that. I had I copied earlier on, I mistakenly didn't post it.&lt;/P&gt;&lt;P&gt;This is how I created the FINAL data.&lt;/P&gt;&lt;P&gt;libname final "/home/augustinetarkom0/my_courses/";&amp;nbsp;&lt;BR /&gt;FILENAME exam2 "/home/augustinetarkom0/my_courses/RISKFACTORSANDACCESSTOCARE.csv";&lt;/P&gt;&lt;P&gt;PROC IMPORT DATAFILE=exam2&lt;BR /&gt;&amp;nbsp;DBMS=CSV&lt;BR /&gt;&amp;nbsp;OUT=final.exam2;&lt;BR /&gt;&amp;nbsp;GETNAMES=YES;&lt;BR /&gt;RUN;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;* This is to printout the content of the raw data;&lt;BR /&gt;title "Listing of the content of the raw data";&lt;BR /&gt;PROC CONTENTS DATA=final.exam2;&lt;BR /&gt;RUN;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;* Here, I print the last 10 observations of the raw data that is uncleaned;&lt;BR /&gt;title "Listing of first 10 Observations of the Raw uncleaned data";&lt;BR /&gt;proc print data = final.exam2 (obs = 10);&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;* Cleaning the data;&lt;/P&gt;&lt;P&gt;data final;&lt;BR /&gt;set final.exam2;&lt;BR /&gt;&amp;nbsp;array a(*) _numeric_;&lt;BR /&gt;&amp;nbsp;do i=1 to dim(a);&lt;BR /&gt;&amp;nbsp;if a(i) = -1111.1&amp;nbsp; then a(i) = .;&lt;BR /&gt;&amp;nbsp;end;&lt;BR /&gt;&amp;nbsp;drop i;&lt;/P&gt;&lt;P&gt;title "Listing the First 10 obs of the cleaned data";&lt;BR /&gt;proc print data = final (obs = 10);&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;</description>
      <pubDate>Sat, 21 Apr 2018 14:42:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456183#M15663</guid>
      <dc:creator>tarkom</dc:creator>
      <dc:date>2018-04-21T14:42:59Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to make a pie of 10 variables across all the States in US</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456185#M15664</link>
      <description>&lt;P&gt;The numbers are importing with some fuzz factor. i.e., they may appear as -1111.1, but actually contain a bit at the end that makes them appear to SAS as a number that is slightly off from -1111.1. You can read about why that happens by doing a web search for numeric precision.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I think the following will make the corrections that you attempted:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;data final;
  set final.exam2;
  array a(*) _numeric_;
  do i=1 to dim(a);
    if fuzz(a(i)) eq -1111.1  then a(i) = .;
  end;
  drop i;
run;
&lt;/PRE&gt;
&lt;P&gt;Art, CEO, AnalystFinder.com&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 21 Apr 2018 14:58:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456185#M15664</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2018-04-21T14:58:01Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to make a pie of 10 variables across all the States in US</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456187#M15665</link>
      <description>&lt;P&gt;Check your negative values in Means dataset.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/20014iC48F9AFAEB3F7ACF/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 21 Apr 2018 15:09:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456187#M15665</guid>
      <dc:creator>SuryaKiran</dc:creator>
      <dc:date>2018-04-21T15:09:16Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to make a pie of 10 variables across all the States in US</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456188#M15666</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/205971"&gt;@tarkom&lt;/a&gt;: You apparently have two additional numbers that contain negative values. If they also represent missing numbers, then you'd have to convert them as well.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I think the following will change those three sets of negative values to missing:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;data final;
  set final.exam2;
  array a(*) _numeric_;
  do i=1 to dim(a);
    if fuzz(a(i)) in (-1111.1,-2222,-2222.2)  then a(i) = .;
  end;
  drop i;
run;
&lt;/PRE&gt;
&lt;P&gt;Art, CEO, AnalystFinder.com&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 21 Apr 2018 15:27:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456188#M15666</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2018-04-21T15:27:08Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to make a pie of 10 variables across all the States in US</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456190#M15667</link>
      <description>&lt;P&gt;Okay, Thank you all very much for your quick response.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;That is the problem I have.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How can I make the pie chart if there is a mean value of negative in it. Is there anyway to go about that?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As always, I appreciate your responses.&lt;/P&gt;</description>
      <pubDate>Sat, 21 Apr 2018 15:30:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456190#M15667</guid>
      <dc:creator>tarkom</dc:creator>
      <dc:date>2018-04-21T15:30:54Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to make a pie of 10 variables across all the States in US</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456192#M15668</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13711"&gt;@art297&lt;/a&gt;Thank you very much. I am going to try that out right away. This sounds refreshing.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I appreciate that.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;</description>
      <pubDate>Sat, 21 Apr 2018 15:33:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456192#M15668</guid>
      <dc:creator>tarkom</dc:creator>
      <dc:date>2018-04-21T15:33:11Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to make a pie of 10 variables across all the States in US</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456198#M15669</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13711"&gt;@art297&lt;/a&gt; Thanks for pointing out that. I get some pie charts. But I have to read the report to make sure what the -2222 means. I am unsure as to whether it is used as missing value.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I really do appreciate your input.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Kind Regards,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;tarkom&lt;/P&gt;</description>
      <pubDate>Sat, 21 Apr 2018 15:50:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Unable-to-make-a-pie-of-10-variables-across-all-the-States-in-US/m-p/456198#M15669</guid>
      <dc:creator>tarkom</dc:creator>
      <dc:date>2018-04-21T15:50:19Z</dc:date>
    </item>
  </channel>
</rss>

