<?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 how to get percentage as 99.9 in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/how-to-get-percentage-as-99-9/m-p/444398#M111256</link>
    <description>&lt;P&gt;When I'm using format as 5.1 or 6.1 on z variable , I'm getting 100 percentage in z variable. I need it 99.9 as required output .please someone suggest on it...&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;data _null_;&lt;BR /&gt;x = 2202;&lt;BR /&gt;y= 2203;&lt;BR /&gt;z=x/y*100;&lt;BR /&gt;z1 = put(z,5.1);&lt;BR /&gt;put x y z z1= ;&lt;BR /&gt;run;&lt;/P&gt;</description>
    <pubDate>Sat, 10 Mar 2018 15:07:01 GMT</pubDate>
    <dc:creator>rajeshalwayswel</dc:creator>
    <dc:date>2018-03-10T15:07:01Z</dc:date>
    <item>
      <title>how to get percentage as 99.9</title>
      <link>https://communities.sas.com/t5/SAS-Programming/how-to-get-percentage-as-99-9/m-p/444398#M111256</link>
      <description>&lt;P&gt;When I'm using format as 5.1 or 6.1 on z variable , I'm getting 100 percentage in z variable. I need it 99.9 as required output .please someone suggest on it...&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;data _null_;&lt;BR /&gt;x = 2202;&lt;BR /&gt;y= 2203;&lt;BR /&gt;z=x/y*100;&lt;BR /&gt;z1 = put(z,5.1);&lt;BR /&gt;put x y z z1= ;&lt;BR /&gt;run;&lt;/P&gt;</description>
      <pubDate>Sat, 10 Mar 2018 15:07:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/how-to-get-percentage-as-99-9/m-p/444398#M111256</guid>
      <dc:creator>rajeshalwayswel</dc:creator>
      <dc:date>2018-03-10T15:07:01Z</dc:date>
    </item>
    <item>
      <title>Re: how to get percentage as 99.9</title>
      <link>https://communities.sas.com/t5/SAS-Programming/how-to-get-percentage-as-99-9/m-p/444401#M111257</link>
      <description>&lt;P&gt;Hi:&lt;/P&gt;
&lt;P&gt;&amp;nbsp; A picture format will not round the number. Here's some code to test, a slightly different version of your code.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc format;
  picture pctnr low-high='099.9';
run;


data nums;
length z2 $5;
x = 2202;
y= 2203;
z=x/y*100;
z1=z;
z2 = put(z,pctnr.);
put x= y= z= z1= z2=;
run;

proc print data=nums label;
var x y z z1 z2;
label z='z uses sas format'
      z1='z1 uses picture custom format'
      z2='z2 is char var using picture format';
format z 5.1 z1 pctnr.;
run;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Cynthia&lt;/P&gt;</description>
      <pubDate>Sat, 10 Mar 2018 15:31:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/how-to-get-percentage-as-99-9/m-p/444401#M111257</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2018-03-10T15:31:54Z</dc:date>
    </item>
    <item>
      <title>Re: how to get percentage as 99.9</title>
      <link>https://communities.sas.com/t5/SAS-Programming/how-to-get-percentage-as-99-9/m-p/444410#M111260</link>
      <description>&lt;P&gt;Be advised that 99.9 will be mathematically wrong, as 99.954607354 must be rounded &lt;EM&gt;up&lt;/EM&gt; (per definition) if only 1 fractional digit can be displayed.&lt;/P&gt;
&lt;P&gt;The more correct method would be to use a 5.2 format in the put() function.&lt;/P&gt;</description>
      <pubDate>Sat, 10 Mar 2018 16:12:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/how-to-get-percentage-as-99-9/m-p/444410#M111260</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2018-03-10T16:12:46Z</dc:date>
    </item>
  </channel>
</rss>

