<?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: Length issue for numeric variables in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Length-issue-for-numeric-variables/m-p/934744#M367540</link>
    <description>&lt;P&gt;SAS numbers are always stored in 8 bytes floating point. For storage in datasets, this length can be reduced down to 3 bytes, but during processing it's always 8.&lt;/P&gt;
&lt;P&gt;The maximum&amp;nbsp;&lt;EM&gt;precision&lt;/EM&gt; because of this is between 15 and 16 decimal digits, which is sufficient for all kinds of statistical analysis.&lt;/P&gt;
&lt;P&gt;Anything which needs more precision is most likely not a number, but some kind of a code and must be stored as character.&lt;/P&gt;</description>
    <pubDate>Fri, 05 Jul 2024 07:24:34 GMT</pubDate>
    <dc:creator>Kurt_Bremser</dc:creator>
    <dc:date>2024-07-05T07:24:34Z</dc:date>
    <item>
      <title>Length issue for numeric variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Length-issue-for-numeric-variables/m-p/934738#M367539</link>
      <description>&lt;BLOCKQUOTE&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data digits_split;
infile datalines missover;
length digits 255;
input digits ;
datalines;
1234567899999999999999999999999999999999
5547
3324
120
1005
11
2
;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Hi Experts,&lt;/P&gt;
&lt;P&gt;can you please explain variable length 3-8 even if I have given explicit length for digits variable how to get complete digits without convert numeric to char&amp;nbsp; and what is max numeric length in SAS&amp;nbsp;&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;</description>
      <pubDate>Fri, 05 Jul 2024 06:16:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Length-issue-for-numeric-variables/m-p/934738#M367539</guid>
      <dc:creator>pavank</dc:creator>
      <dc:date>2024-07-05T06:16:14Z</dc:date>
    </item>
    <item>
      <title>Re: Length issue for numeric variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Length-issue-for-numeric-variables/m-p/934744#M367540</link>
      <description>&lt;P&gt;SAS numbers are always stored in 8 bytes floating point. For storage in datasets, this length can be reduced down to 3 bytes, but during processing it's always 8.&lt;/P&gt;
&lt;P&gt;The maximum&amp;nbsp;&lt;EM&gt;precision&lt;/EM&gt; because of this is between 15 and 16 decimal digits, which is sufficient for all kinds of statistical analysis.&lt;/P&gt;
&lt;P&gt;Anything which needs more precision is most likely not a number, but some kind of a code and must be stored as character.&lt;/P&gt;</description>
      <pubDate>Fri, 05 Jul 2024 07:24:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Length-issue-for-numeric-variables/m-p/934744#M367540</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2024-07-05T07:24:34Z</dc:date>
    </item>
    <item>
      <title>Re: Length issue for numeric variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Length-issue-for-numeric-variables/m-p/934747#M367541</link>
      <description>&lt;P&gt;PS the technical details of 8 byte floating point can be found&amp;nbsp;&lt;A href="https://en.m.wikipedia.org/wiki/IEEE_754" target="_blank" rel="noopener"&gt;here&lt;/A&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 05 Jul 2024 07:44:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Length-issue-for-numeric-variables/m-p/934747#M367541</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2024-07-05T07:44:10Z</dc:date>
    </item>
    <item>
      <title>Re: Length issue for numeric variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Length-issue-for-numeric-variables/m-p/934775#M367543</link>
      <description>&lt;P&gt;Also to note:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;1.&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;SAS numbers are always stored in 8 bytes floating point&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Not only SAS, that's true for numbers in software running on PC or unix.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;2.&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;can you please explain variable length 3-8&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;The length of 8 represents the number of bytes used to store the number (sign, mantissa and exponent), not the number of digits.&lt;/P&gt;</description>
      <pubDate>Fri, 05 Jul 2024 12:23:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Length-issue-for-numeric-variables/m-p/934775#M367543</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2024-07-05T12:23:52Z</dc:date>
    </item>
  </channel>
</rss>

