<?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: SAS VA formul with a string condition in SAS Visual Analytics</title>
    <link>https://communities.sas.com/t5/SAS-Visual-Analytics/SAS-VA-formul-with-a-string-condition/m-p/655534#M13848</link>
    <description>&lt;P&gt;The message is coming from the expression Position &amp;lt;&amp;gt; "FAKT_STD". &amp;nbsp; To get this to work, turn that into a numeric expression by doing the following:&lt;/P&gt;
&lt;P&gt;1. Create a numeric calculated data item called&amp;nbsp; Position Flag.&lt;/P&gt;
&lt;P&gt;2. In the expression for Position Flag make it look like: &amp;nbsp; &amp;nbsp; If Position &amp;lt;&amp;gt; "FAKT_STD" return 1 else 0&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;3. Modify your % v.UMS.(Lf.M) calculation and replace (Position &amp;lt;&amp;gt; "FAKT_STD") with "Position Flag"n &amp;gt;= 1&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 09 Jun 2020 14:08:49 GMT</pubDate>
    <dc:creator>KeithM</dc:creator>
    <dc:date>2020-06-09T14:08:49Z</dc:date>
    <item>
      <title>SAS VA formul with a string condition</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/SAS-VA-formul-with-a-string-condition/m-p/655496#M13844</link>
      <description>&lt;P&gt;Hello,&lt;BR /&gt;I have in SAS VA an aggregated measure as follows:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;IF ( ( Sum [_ByGroup_] ('Lf. Monat'n) &amp;lt;&amp;gt; 0 ) AND ( Sum [_ByGroup_] ('UMS'n) &amp;lt;&amp;gt; 0 ) )&lt;BR /&gt;RETURN ( Sum [_ByGroup_] ('Lf. Monat'n) / Sum [_ByGroup_] ('UMS'n) )&lt;BR /&gt;ELSE 0&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This formula calculates now on all members of a category called POSITION. I want to limit now the calculation on all positions except the one calle "FAKT_STD". So it should look similar to this one:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;IF ( ( Sum [_ByGroup_] ('Lf. Monat'n) &amp;lt;&amp;gt; 0 ) AND ( Sum [_ByGroup_] ('UMS'n) &amp;lt;&amp;gt; 0 )&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;AND ( POSITION&amp;lt;&amp;gt; 'FAKT_STD' )&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;)&lt;BR /&gt;RETURN ( Sum [_ByGroup_] ('Lf. Monat'n) / Sum [_ByGroup_] ('UMS'n) )&lt;BR /&gt;ELSE 0&lt;/P&gt;&lt;P&gt;Unfortunately this expression is not accepted by the system.&lt;/P&gt;&lt;P&gt;Does anybody know how the expression should look like?&lt;/P&gt;&lt;P&gt;Thx&lt;/P&gt;&lt;P&gt;Robert&lt;/P&gt;</description>
      <pubDate>Tue, 09 Jun 2020 12:20:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/SAS-VA-formul-with-a-string-condition/m-p/655496#M13844</guid>
      <dc:creator>RHECK</dc:creator>
      <dc:date>2020-06-09T12:20:22Z</dc:date>
    </item>
    <item>
      <title>Re: SAS VA formul with a string condition</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/SAS-VA-formul-with-a-string-condition/m-p/655509#M13845</link>
      <description>&lt;P&gt;Can you tell us which version of Visual Analytics you are using?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;When you say "not accepted," is there an error message or a warning in the Expression dialog box? If yes, what is it? If not, then can you provide more details about "not accepted."&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 09 Jun 2020 13:08:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/SAS-VA-formul-with-a-string-condition/m-p/655509#M13845</guid>
      <dc:creator>Madelyn_SAS</dc:creator>
      <dc:date>2020-06-09T13:08:34Z</dc:date>
    </item>
    <item>
      <title>Re: SAS VA formul with a string condition</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/SAS-VA-formul-with-a-string-condition/m-p/655524#M13847</link>
      <description>&lt;P&gt;Hi Madelyn,&lt;/P&gt;&lt;P&gt;We are using VA 7.3.&lt;/P&gt;&lt;P&gt;The meesage that I get is the following:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="RHECK_0-1591709938534.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/41590iDC186098E11AD25C/image-size/medium?v=v2&amp;amp;px=400" role="button" title="RHECK_0-1591709938534.png" alt="RHECK_0-1591709938534.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;The german message ranslate to "Arguments should be of same type. One type is numeric the other alphanumeric"&lt;/P&gt;&lt;P&gt;Thx&lt;/P&gt;&lt;P&gt;Robert&lt;/P&gt;</description>
      <pubDate>Tue, 09 Jun 2020 13:40:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/SAS-VA-formul-with-a-string-condition/m-p/655524#M13847</guid>
      <dc:creator>RHECK</dc:creator>
      <dc:date>2020-06-09T13:40:11Z</dc:date>
    </item>
    <item>
      <title>Re: SAS VA formul with a string condition</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/SAS-VA-formul-with-a-string-condition/m-p/655534#M13848</link>
      <description>&lt;P&gt;The message is coming from the expression Position &amp;lt;&amp;gt; "FAKT_STD". &amp;nbsp; To get this to work, turn that into a numeric expression by doing the following:&lt;/P&gt;
&lt;P&gt;1. Create a numeric calculated data item called&amp;nbsp; Position Flag.&lt;/P&gt;
&lt;P&gt;2. In the expression for Position Flag make it look like: &amp;nbsp; &amp;nbsp; If Position &amp;lt;&amp;gt; "FAKT_STD" return 1 else 0&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;3. Modify your % v.UMS.(Lf.M) calculation and replace (Position &amp;lt;&amp;gt; "FAKT_STD") with "Position Flag"n &amp;gt;= 1&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 09 Jun 2020 14:08:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/SAS-VA-formul-with-a-string-condition/m-p/655534#M13848</guid>
      <dc:creator>KeithM</dc:creator>
      <dc:date>2020-06-09T14:08:49Z</dc:date>
    </item>
  </channel>
</rss>

