<?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 Compare Output - Cater Rounded values on Base dataset in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410755#M100376</link>
    <description>&lt;P&gt;Proc compare does not round. The data is different.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;One way to do what you want may be to compare within say a thousandth.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Add options:&lt;FONT face="courier new,courier"&gt; method=absolute criterion=0.001&lt;/FONT&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 06 Nov 2017 04:08:15 GMT</pubDate>
    <dc:creator>ChrisNZ</dc:creator>
    <dc:date>2017-11-06T04:08:15Z</dc:date>
    <item>
      <title>PROC Compare Output - Cater Rounded values on Base dataset</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410746#M100370</link>
      <description>&lt;P&gt;Hi all,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I performed PROC COMPARE to a dataset, as purpose of UAT, I have to check the accuracy of the data. In the first stage, I include the data that we have and saw A LOT of discrepancies. Hence, I tried to used same dataset which been used to upload into the server, then performed PROC COMPARE, I found out, IT STILL HAVE UNEQUAL VALUES.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Through eyeball checking, the base and compare data set, does HAVE SAME VALUES. But when performing PROC COMPARE, I realized that the &lt;STRONG&gt;&lt;U&gt;variables in Base data set has been rounded to a number&lt;/U&gt;&lt;/STRONG&gt; which I dont know about.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As an example:&lt;/P&gt;&lt;P&gt;Base: 0.38459348 ------ Compare:&amp;nbsp;&amp;nbsp;&lt;SPAN&gt;0.38459348&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Output &amp;gt;&amp;gt; 0.3846 base ---- 0.38459348 &amp;gt;&amp;gt; Different: -0.00000652&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How can I cater this problem? I want the base dataset to be read as it is, without rounding up any values on the Base dataset&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Kindly help. Really appreciate your help!&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Nov 2017 02:50:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410746#M100370</guid>
      <dc:creator>AieuYuhara</dc:creator>
      <dc:date>2017-11-06T02:50:36Z</dc:date>
    </item>
    <item>
      <title>Re: PROC Compare Output - Cater Rounded values on Base dataset</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410755#M100376</link>
      <description>&lt;P&gt;Proc compare does not round. The data is different.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;One way to do what you want may be to compare within say a thousandth.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Add options:&lt;FONT face="courier new,courier"&gt; method=absolute criterion=0.001&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Nov 2017 04:08:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410755#M100376</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2017-11-06T04:08:15Z</dc:date>
    </item>
    <item>
      <title>Re: PROC Compare Output - Cater Rounded values on Base dataset</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410764#M100380</link>
      <description>&lt;P&gt;Tried before, and still couldn't capture that the data is actually the same. The problem only appear to the numbers in the Base dataset, which is exactly the same as the one I uploaded to compare with. Logically, it should be an equal values for all fields.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Plus, I noticed that in the output, it only have 4 decimal points max whereas my data has 8 decimal points. Any other way to cater this difference? Like letting the base data set read the way it is, which is 8 decimal points instead of just 4..?&lt;/P&gt;</description>
      <pubDate>Mon, 06 Nov 2017 05:32:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410764#M100380</guid>
      <dc:creator>AieuYuhara</dc:creator>
      <dc:date>2017-11-06T05:32:09Z</dc:date>
    </item>
    <item>
      <title>Re: PROC Compare Output - Cater Rounded values on Base dataset</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410765#M100381</link>
      <description>1. Did you try these 2 options? They will solve the issue with the data example you showed. &lt;BR /&gt;2. Are the formats the same? &lt;BR /&gt;3. Just checking. They are numeric variables right?</description>
      <pubDate>Mon, 06 Nov 2017 06:12:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410765#M100381</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2017-11-06T06:12:16Z</dc:date>
    </item>
    <item>
      <title>Re: PROC Compare Output - Cater Rounded values on Base dataset</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410766#M100382</link>
      <description>&lt;P&gt;1. Yes. Below is the example output I got:&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;FONT size="2"&gt;Base ABC&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT size="2"&gt;Compare ABC&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT size="2"&gt;Diff.&lt;/FONT&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;FONT size="2"&gt;0.254&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT size="2"&gt;0.25396771&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT size="2"&gt;-3.229E-05&lt;/FONT&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;FONT size="2"&gt;0.1234&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT size="2"&gt;0.12340589&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT size="2"&gt;5.89E-05&lt;/FONT&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As noticed, the base ABC value is rounded. From eyeball checking, the base table ABC have exactly same value and same format as Compare ABC. But when we use to compare between both table, it only compares 4 decimal places (from its actual 8 decimal points) vs 8 decimal values (as in the compare table). It didnt round up any value in compare table, but it does round up the value in the base table.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. Yes. Format is the same. Numeric BEST12.&lt;/P&gt;&lt;P&gt;3. Yes. Numeric Variable.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Nov 2017 06:38:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410766#M100382</guid>
      <dc:creator>AieuYuhara</dc:creator>
      <dc:date>2017-11-06T06:38:22Z</dc:date>
    </item>
    <item>
      <title>Re: PROC Compare Output - Cater Rounded values on Base dataset</title>
      <link>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410783#M100386</link>
      <description>&lt;P&gt;You are doing something wrong. The comparison works fine here.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data T1;
  X=0.1234;
data T2;
  X=0.12340589;
proc compare data=T1 compare=T2 method=absolute criterion=0.001;
run; &lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="branch"&gt;
&lt;DIV&gt;
&lt;DIV align="center"&gt;
&lt;TABLE summary="Page Layout" cellspacing="0" cellpadding="0"&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD&gt;
&lt;PRE class="batch"&gt;                                                                                               
                                   Values Comparison Summary                                   
                                                                                               
                Number of Variables Compared with All Observations Equal: 1.                   
                Number of Variables Compared with Some Observations Unequal: 0.                
                Total Number of Values which Compare Unequal: 0.                               
                Total Number of Values not EXACTLY Equal: 1.                                   
                Maximum Difference: 0.00000589.  &lt;/PRE&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Nov 2017 09:26:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/PROC-Compare-Output-Cater-Rounded-values-on-Base-dataset/m-p/410783#M100386</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2017-11-06T09:26:20Z</dc:date>
    </item>
  </channel>
</rss>

