<?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 COMPGED function in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/COMPGED-function/m-p/26898#M4820</link>
    <description>I asked for help from SAS tech support on a specific example of a COMPGED function application, but was only referred to the SAS documentation.  I would appreciate it if someone familiar with the COMPGED function can give some insight into the following:&lt;BR /&gt;
&lt;BR /&gt;
I have compared the following two text strings using this function:&lt;BR /&gt;
&lt;BR /&gt;
COMPGED('F350SUPERDUTYDRWCREWCAB','F350SUPERDUTYCREWCAB172WB')&lt;BR /&gt;
&lt;BR /&gt;
and the result is 620.  I'm unable to figure out the operations that were used in determining this cost, and I have not changed the default costs.  It seems to me that one way to construct string 1 from string 2 is to&lt;BR /&gt;
1) truncate the last 5 characters (cost = 10*5 = 50)&lt;BR /&gt;
2) insert the 3 characters DRW (cost = 100*3 = 300)&lt;BR /&gt;
for a total cost of 350.  Can someone explain why COMPGED returns 620?</description>
    <pubDate>Tue, 02 Nov 2010 17:01:59 GMT</pubDate>
    <dc:creator>sf388</dc:creator>
    <dc:date>2010-11-02T17:01:59Z</dc:date>
    <item>
      <title>COMPGED function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/COMPGED-function/m-p/26898#M4820</link>
      <description>I asked for help from SAS tech support on a specific example of a COMPGED function application, but was only referred to the SAS documentation.  I would appreciate it if someone familiar with the COMPGED function can give some insight into the following:&lt;BR /&gt;
&lt;BR /&gt;
I have compared the following two text strings using this function:&lt;BR /&gt;
&lt;BR /&gt;
COMPGED('F350SUPERDUTYDRWCREWCAB','F350SUPERDUTYCREWCAB172WB')&lt;BR /&gt;
&lt;BR /&gt;
and the result is 620.  I'm unable to figure out the operations that were used in determining this cost, and I have not changed the default costs.  It seems to me that one way to construct string 1 from string 2 is to&lt;BR /&gt;
1) truncate the last 5 characters (cost = 10*5 = 50)&lt;BR /&gt;
2) insert the 3 characters DRW (cost = 100*3 = 300)&lt;BR /&gt;
for a total cost of 350.  Can someone explain why COMPGED returns 620?</description>
      <pubDate>Tue, 02 Nov 2010 17:01:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/COMPGED-function/m-p/26898#M4820</guid>
      <dc:creator>sf388</dc:creator>
      <dc:date>2010-11-02T17:01:59Z</dc:date>
    </item>
    <item>
      <title>Re: COMPGED function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/COMPGED-function/m-p/26899#M4821</link>
      <description>Is it that the last 2 characters (WB) get "truncated" (10*2=20) and then the "172" gets "deleted" (100*3=300) because string2 is 2 characters longer than string1?&lt;BR /&gt;
So, the cost of removing "172WB" is actually 320, not 50?</description>
      <pubDate>Tue, 02 Nov 2010 17:12:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/COMPGED-function/m-p/26899#M4821</guid>
      <dc:creator>sf388</dc:creator>
      <dc:date>2010-11-02T17:12:00Z</dc:date>
    </item>
    <item>
      <title>Re: COMPGED function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/COMPGED-function/m-p/26900#M4822</link>
      <description>How about Google search the SAS.COM support site?&lt;BR /&gt;
&lt;BR /&gt;
Scott Barry&lt;BR /&gt;
SBBWorks, Inc.&lt;BR /&gt;
&lt;BR /&gt;
Suggested Google advanced search argument, this topic / post:&lt;BR /&gt;
+COMPGED +example site:sas.com</description>
      <pubDate>Tue, 02 Nov 2010 17:15:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/COMPGED-function/m-p/26900#M4822</guid>
      <dc:creator>sbb</dc:creator>
      <dc:date>2010-11-02T17:15:09Z</dc:date>
    </item>
  </channel>
</rss>

