<?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: Change Stack Grouping based on dropdown choice in SAS Visual Analytics</title>
    <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340939#M6624</link>
    <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/73706"&gt;@Lodewijk&lt;/a&gt;&amp;nbsp;Thank you! Unfortunately, that confirms my thoughts. It is not possible ti add the labels of the different grousp...&lt;/P&gt;</description>
    <pubDate>Tue, 14 Mar 2017 19:52:19 GMT</pubDate>
    <dc:creator>rmalcata</dc:creator>
    <dc:date>2017-03-14T19:52:19Z</dc:date>
    <item>
      <title>Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/263540#M3901</link>
      <description>&lt;P&gt;We are trying to find out if it is possible to change the grouping of a bar chart based on the choices in a drop down. &amp;nbsp;An example of what we are going for can be found here:&amp;nbsp;&lt;A href="https://www.purdue.edu/datadigest/" target="_blank"&gt;https://www.purdue.edu/datadigest/&lt;/A&gt; under the "Student Enrollment" report. &amp;nbsp;What we are looking to do is the equivalent of the "Break Color By" drop down in the left hand menu. &amp;nbsp;The rest of the dropdowns seem to be traditional filters.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Wed, 13 Apr 2016 14:52:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/263540#M3901</guid>
      <dc:creator>dakuwan</dc:creator>
      <dc:date>2016-04-13T14:52:35Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/263657#M3905</link>
      <description>&lt;P&gt;Hi dakuwan,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is possible, but you need to create a small reference table and load it in SAS VA with the column names you want to be able to choose from. This can be a one column table, so it's very small. This table needs to be added as a datasource to the report. Use the category in this reference table to populate the dropdown list.&amp;nbsp;Now assign a parameter to the dropdown list.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Next create a new calculated item 'Grouped by' (in the original dataset). This calculated item uses the if - return&amp;nbsp;- else logic to populate it with the chosen value of the dropdown list. The code looks something like this:&lt;/P&gt;&lt;PRE&gt;IF ('p_dropdown'p = 'column A') 
RETURN ('Column A'n) 
ELSE (
            IF ('p_dropdown'p = 'column B')  
            RETURN ('Column B'n) 
            ELSE ('Column C'n)
           )&lt;/PRE&gt;&lt;P&gt;Now assign this calculated item 'Grouped by' to the group role in the bar chart and the magic should happen &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;-&amp;nbsp;Lodewijk&lt;/P&gt;</description>
      <pubDate>Wed, 13 Apr 2016 20:19:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/263657#M3905</guid>
      <dc:creator>Lodewijk</dc:creator>
      <dc:date>2016-04-13T20:19:06Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/263893#M3912</link>
      <description>&lt;P&gt;Thanks, this worked perfectly and was a lot simpler to implement than i expected.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Really appreciate the help.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Apr 2016 14:52:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/263893#M3912</guid>
      <dc:creator>dakuwan</dc:creator>
      <dc:date>2016-04-14T14:52:00Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/265275#M3961</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/73706"&gt;@Lodewijk﻿&lt;/a&gt;&amp;nbsp;Thanks for this. Much appreciated. I did try something similar but it seems I got confused as to which data source had to contain what field, though it makes sense now.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I seems like VA needs to have a character parameter that can store/accept a bunch of values, one of which is current. Like the numeric parameter. Having to have a&amp;nbsp;table just for menu entries is sad. Do you read this VA devs?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I limited the&amp;nbsp;sadness by adding a step to your process. I import a table called blank entries that contains values 01 to 99&amp;nbsp;, and I create a custom category for each drop-down list&amp;nbsp;with the values I need. This way, I only need one&amp;nbsp;sad menu entry table for all reports.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;A limitation to the&amp;nbsp;process you demonstrated&amp;nbsp;is that aggregated measures cannot be displayed. I worked around this by creating an aggregated measure instead of a calculated&amp;nbsp;item, so I can display both in my report (the % format is lacking however):&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;IF ( 'p_dropdown'p = '# A' ) 
RETURN Sum [_ByGroup_] ( '# A'n ) 
ELSE (
            IF ( 'p_dropdown'p = '% A' )  
            RETURN ( '% A'n * 100 ) 
            ELSE  ...&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Creating VA reports is fun when you&amp;nbsp;accept it&amp;nbsp;with the right mind set: it's a challenge much&amp;nbsp;like playing Lego; you try and build systems with a set of overly simplistic tools, and you rack your brains trying to devise smart solutions. But really, the needs outlined&amp;nbsp;here are simple, common and straightforward. The tool should natively enable this.&lt;/P&gt;</description>
      <pubDate>Thu, 21 Apr 2016 00:59:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/265275#M3961</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2016-04-21T00:59:03Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/266358#M4007</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/16961"&gt;@ChrisNZ﻿&lt;/a&gt;&amp;nbsp;We were running into the same need of having a default that was just the sum. &amp;nbsp;In our case this was wanting to default to a total headcount when the bars weren't broken by whatever choice they had made. &amp;nbsp;So our chart is breaking by gender, ethnicity, location, etc. &amp;nbsp;Each choice breaks up the headcount and looks good. &amp;nbsp;What we're missing is that last else statement where if nothing is chosen the chart is just a single bar of the headcount unbroken.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Could you elaborate on how you did this? &amp;nbsp;Looking at your example i was confused by what the return sum line. &amp;nbsp;That may be due to my overall lack of SAS experience and straightforward for others.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 26 Apr 2016 13:22:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/266358#M4007</guid>
      <dc:creator>dakuwan</dc:creator>
      <dc:date>2016-04-26T13:22:03Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/266908#M4022</link>
      <description>&lt;P&gt;Have you&amp;nbsp; tried&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;IF        ( 'p_dropdown'p = 'By Gender' )   RETURN  ( 'GENDER'n ) 
ELSE IF ( 'p_dropdown'p = 'By Age' )  RETURN ( 'AGE'n ) 
            ELSE 'No Split'&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 28 Apr 2016 06:59:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/266908#M4022</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2016-04-28T06:59:52Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/266958#M4025</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/16961"&gt;@ChrisNZ﻿&lt;/a&gt;. &amp;nbsp;That worked perfectly. &amp;nbsp;I didnt realize i could just put anything in there and it would default to showing it unbroken. &amp;nbsp;I assumed i had to either reference a parameter or data element.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks again.&lt;/P&gt;</description>
      <pubDate>Thu, 28 Apr 2016 14:22:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/266958#M4025</guid>
      <dc:creator>dakuwan</dc:creator>
      <dc:date>2016-04-28T14:22:45Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/267124#M4028</link>
      <description>&lt;P&gt;Now if there was a way to compute split percentage to 100% without having to precalculate all the totals in the data...&lt;/P&gt;</description>
      <pubDate>Thu, 28 Apr 2016 21:52:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/267124#M4028</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2016-04-28T21:52:00Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340266#M6575</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/16961"&gt;@ChrisNZ&lt;/a&gt;&lt;/P&gt;&lt;P&gt;Hi Chris,&lt;BR /&gt;thank you for the post, it is really helpful. Looking at your graph, you have the data labels for each groups within the stach graph. Can you please let me know how you achieved this in SAS VA?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/7676i8BF2F9AD4F840393/image-size/original?v=1.0&amp;amp;px=-1" border="0" alt="stack bar with labels.PNG" title="stack bar with labels.PNG" /&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 12 Mar 2017 21:24:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340266#M6575</guid>
      <dc:creator>rmalcata</dc:creator>
      <dc:date>2017-03-12T21:24:07Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340286#M6578</link>
      <description>&lt;P&gt;I havent worked on VA for almost a year now, it was just a short stint, so I can't help you, sorry. It's too long ago and I can't recall.&lt;/P&gt;</description>
      <pubDate>Mon, 13 Mar 2017 02:07:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340286#M6578</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2017-03-13T02:07:07Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340289#M6579</link>
      <description>&lt;P&gt;Thanks for the reply, no matter what. Do &amp;nbsp;you remember if you developed the graphs in VA or it was in another visualization tool (they look like Tableau)?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 13 Mar 2017 02:22:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340289#M6579</guid>
      <dc:creator>rmalcata</dc:creator>
      <dc:date>2017-03-13T02:22:42Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340291#M6580</link>
      <description>&lt;P&gt;All in VA for sure.&lt;/P&gt;</description>
      <pubDate>Mon, 13 Mar 2017 02:36:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340291#M6580</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2017-03-13T02:36:16Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340420#M6599</link>
      <description>&lt;P&gt;The graph you're showing is from the original question&amp;nbsp;from Dakuwan as taken from the website of Purdue. Looking at the website source, it seems that the visualisations are made using Tableau.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As far as I know, it's still not possible to create data labels inside the (stacked) barchart in SAS VA.&lt;/P&gt;</description>
      <pubDate>Mon, 13 Mar 2017 13:57:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340420#M6599</guid>
      <dc:creator>Lodewijk</dc:creator>
      <dc:date>2017-03-13T13:57:18Z</dc:date>
    </item>
    <item>
      <title>Re: Change Stack Grouping based on dropdown choice</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340939#M6624</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/73706"&gt;@Lodewijk&lt;/a&gt;&amp;nbsp;Thank you! Unfortunately, that confirms my thoughts. It is not possible ti add the labels of the different grousp...&lt;/P&gt;</description>
      <pubDate>Tue, 14 Mar 2017 19:52:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/Change-Stack-Grouping-based-on-dropdown-choice/m-p/340939#M6624</guid>
      <dc:creator>rmalcata</dc:creator>
      <dc:date>2017-03-14T19:52:19Z</dc:date>
    </item>
  </channel>
</rss>

