<?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 format question in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609118#M177319</link>
    <description>&lt;P&gt;Thank you so much! I tried to answer this problem below using the data provided. But I got an error saying "&lt;SPAN&gt;Variable CONT not found." I'm not sure what I did wrong? &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;(Variable contry should be country. But it was given in the data by my instructor so I just assume that's correct)&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;A. Write chart procedure statements to produce a vertical bar chart of average energy consumption by country grouped into continent.&lt;BR /&gt;Use the cont format to recode country number into continent name. What would the chart look like if the format were not used?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;proc chart data=demog;
vbar contry/group=cont
SUMVAR=energy type=mean;
run;&lt;/PRE&gt;</description>
    <pubDate>Tue, 03 Dec 2019 16:35:06 GMT</pubDate>
    <dc:creator>Amy0223</dc:creator>
    <dc:date>2019-12-03T16:35:06Z</dc:date>
    <item>
      <title>proc format question</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609092#M177310</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;I get a note below when running the format procedure. I'm not sure how to correct the codes. Any help is greatly appreciated!&lt;/SPAN&gt;&lt;/P&gt;
&lt;DIV id="sasLogNote3_1575387618633" class="sasNote"&gt;NOTE: Format CONT is already on the library WORK.FORMATS.&lt;/DIV&gt;
&lt;DIV id="sasLogNote4_1575387618633" class="sasNote"&gt;NOTE: Format CONT has been output.&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;100 run;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV id="sasLogNote5_1575387618633" class="sasNote"&gt;NOTE: PROCEDURE FORMAT used (Total process time):&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;real time 0.00 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;cpu time 0.00 seconds&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;Below are my codes.&lt;/DIV&gt;
&lt;DIV class="sasNote"&gt;
&lt;PRE&gt;data demog;
  input id contry $ 5-17 pop 19-22 pcturb 24-25 energy 27-29 cult 31-32 
        pasture 34-35 forest 37-38;
cards;
101 China         1062 32  19 11 30 14
107 Japan          122 76 111 13  2 68
113 Philippines     62 40   9 38  4 40
102 India          800 25   7 51  4 21
112 Vietnam         62 19   4 20  1 40
109 Bangladesh     107  .   .  .  .  .
105 Indonesia      175  .   .  .  .  .
110 Paskistan      105 28   6 25  6  4
304 United States  243 74 280 20 26 28
311 Mexico          82 70  50 13 38 23
406 Brazil         141 71  19  9 19 66
508 Nigeria        109 28   7 34 23 16
603 USSR           284 65 176 10 17 42
614 West Germany    61 85 163 30 19 29
615 Italy           57 72  90 41 16 21
;
run;


proc format;
value cont   100-199='Asia'        200-299='Australasia'
             300-399='N. America'  400-499='S. America'
             500-599='Africa'      600-699='Europe';
run;&lt;/PRE&gt;
&lt;/DIV&gt;</description>
      <pubDate>Tue, 03 Dec 2019 15:44:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609092#M177310</guid>
      <dc:creator>Amy0223</dc:creator>
      <dc:date>2019-12-03T15:44:32Z</dc:date>
    </item>
    <item>
      <title>Re: proc format question</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609101#M177312</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There is nothing to correct. This is a simple note that tells you that the format already exists&lt;/P&gt;
&lt;P&gt;because of a previous execution of the program.&lt;/P&gt;</description>
      <pubDate>Tue, 03 Dec 2019 15:59:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609101#M177312</guid>
      <dc:creator>gamotte</dc:creator>
      <dc:date>2019-12-03T15:59:48Z</dc:date>
    </item>
    <item>
      <title>Re: proc format question</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609102#M177313</link>
      <description>&lt;P&gt;The note just tells you that the format already exists in the location, but it is overwritten. There is nothing to correct here, your code looks fine.&lt;/P&gt;</description>
      <pubDate>Tue, 03 Dec 2019 16:00:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609102#M177313</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2019-12-03T16:00:34Z</dc:date>
    </item>
    <item>
      <title>Re: proc format question</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609103#M177314</link>
      <description>&lt;P&gt;You probably don't need to do anything.&amp;nbsp; The message is just saying you are defining CONT, but CONT already existed. So the old definition will be replaced with the new definition.&amp;nbsp; You have probably submitted the same block of code more than once in the current SAS session.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It would only be a problem if you are trying to use the same format name to mean two different things at the same time.&lt;/P&gt;</description>
      <pubDate>Tue, 03 Dec 2019 16:02:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609103#M177314</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2019-12-03T16:02:09Z</dc:date>
    </item>
    <item>
      <title>Re: proc format question</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609108#M177315</link>
      <description>Thank you so much! I greatly appreciate your help!</description>
      <pubDate>Tue, 03 Dec 2019 16:06:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609108#M177315</guid>
      <dc:creator>Amy0223</dc:creator>
      <dc:date>2019-12-03T16:06:57Z</dc:date>
    </item>
    <item>
      <title>Re: proc format question</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609118#M177319</link>
      <description>&lt;P&gt;Thank you so much! I tried to answer this problem below using the data provided. But I got an error saying "&lt;SPAN&gt;Variable CONT not found." I'm not sure what I did wrong? &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;(Variable contry should be country. But it was given in the data by my instructor so I just assume that's correct)&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;A. Write chart procedure statements to produce a vertical bar chart of average energy consumption by country grouped into continent.&lt;BR /&gt;Use the cont format to recode country number into continent name. What would the chart look like if the format were not used?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;proc chart data=demog;
vbar contry/group=cont
SUMVAR=energy type=mean;
run;&lt;/PRE&gt;</description>
      <pubDate>Tue, 03 Dec 2019 16:35:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609118#M177319</guid>
      <dc:creator>Amy0223</dc:creator>
      <dc:date>2019-12-03T16:35:06Z</dc:date>
    </item>
    <item>
      <title>Re: proc format question</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609120#M177320</link>
      <description>&lt;P&gt;What variable is being graphed?&lt;/P&gt;
&lt;P&gt;Sounds like COUNTRY (how ever it is named) is the GROUP= variable.&amp;nbsp; You just want to use a FORMAT statement to tell it use the formatted values for the groups instead of the raw values.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;.... group=country .... ;
format country cont. ;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 03 Dec 2019 16:39:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609120#M177320</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2019-12-03T16:39:42Z</dc:date>
    </item>
    <item>
      <title>Re: proc format question</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609122#M177321</link>
      <description>Thank you for taking the time to help me. I will try it this way.</description>
      <pubDate>Tue, 03 Dec 2019 17:04:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-format-question/m-p/609122#M177321</guid>
      <dc:creator>Amy0223</dc:creator>
      <dc:date>2019-12-03T17:04:10Z</dc:date>
    </item>
  </channel>
</rss>

