BookmarkSubscribeRSS Feed
MarkusWeick
Barite | Level 11

I think there are tow tasks:

First, having overlapping groups (which doesn't work in one costum category).

Second, showing different columns based on a button bar selection.

(For the second task @Sam_SAS showed a nice workaround in Solved: Creating dynamic measures in stacked bar chart - SAS Support Communities)

Please keep the community friendly.
Like posts you agree with or like. Mark helpful answers as “accepted solutions”. Generally have a look at https://communities.sas.com/t5/Getting-Started/tkb-p/community_articles
vallsas
Pyrite | Level 9
Hi @MarkusWeick
I mentioned in the first post as custom_column diffferet groups and all in one group in the same custom column so that i can use in button bar.
Cutom_cat_colum
group1 : AAA
BBB
CCC
group2 :GGG
EEE
Group3: DDD
FFF
Group4:AAA
BBB
CCC
DDD
EEE
FFF

as we are already selected the values into different groups then we dont have a option to create group4 in the custom_category because the values we are already moved to group1 group2 group3 and GROUP4 is all the group values. so we cant create a group4.
sorry for the confusion. hope in the last post you have got clear idea what is needed.
thanks
t
MarkusWeick
Barite | Level 11

Hi @vallsas,

please give the following apporach a try:

1.1     Button bar for selection of parameter values

1.1.1    Defining and uploading the values for the Buttons

We build an Excel file (“Groupings 2.xlsx”) with one column which contains the possible parameter values, which we want to show on the buttons of the button bar under a column name:

Bruehl_0-1661754890995.png

We then upload this table into VA.

1.1.2    Definiton of a character parameter

We define a new data item as parameter of type “Character” and name it “Choice”

Bruehl_1-1661755004049.png

1.1.3    Definition of a button bar

We drag a button bar object to the report page.

Before we assign the roles to the button bar, we activate the table with the values we want to assign with the button bar:

Bruehl_2-1661755116227.png

Then we assign the roles to the button bar:

Bruehl_3-1661755168794.png

2.1     Calculated item which contains the chosen group

Now we define a “new calculated item”:

Bruehl_4-1661755267646.png

With nested if-clauses we get a column which contains the values for the group which is defined by the choice in the button bar (via the parameter):

Bruehl_5-1661755290164.png

 

Bruehl_6-1661755303430.png

 

1.4     Creating an object that shows the calculated item

 

Bruehl_7-1661755356491.png

 

If we want to omit the line with the missing values, we can add a filter to the list table and deactivate the “Include missing values” option:

Bruehl_8-1661755378807.png

 

 

 

Please keep the community friendly.
Like posts you agree with or like. Mark helpful answers as “accepted solutions”. Generally have a look at https://communities.sas.com/t5/Getting-Started/tkb-p/community_articles
MarkusWeick
Barite | Level 11

Hi @vallsas,

did it work for you?

Best

Markus

Please keep the community friendly.
Like posts you agree with or like. Mark helpful answers as “accepted solutions”. Generally have a look at https://communities.sas.com/t5/Getting-Started/tkb-p/community_articles
vallsas
Pyrite | Level 9

Hi Markus,

 

departmenttask_list
aaa1001
bbb1002
ccc1003
ddd1004
ccc1004
ccc1005

 

there is no column which contains groups with all value , so I cant choose in the if condition to select the values.

requirement is : when we use button bar by department we get as per the example: 5 dep and on the same button bar we would like to have All so when user would like to see statistics of all the all the departments stats then he will choose all otherwise dept. 

as we don't have all in the new customized category as I have created custom category to define the 5 groups and in the custom category we dont have options to choose all as one group.

 

 

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

Tips for filtering data sources in SAS Visual Analytics

See how to use one filter for multiple data sources by mapping your data from SAS’ Alexandria McCall.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 19 replies
  • 1405 views
  • 0 likes
  • 2 in conversation