Skip to main content
Announcements
Global Transformation Awards! Applications are now open. Submit Entry
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Straight Table (totals and %)

Hi,

I have a straight table that looks like this.

StatusGroup AGroup B
Active64
Completed1216

Dimension is simply [Status]

Expression for Group A is count({<[Group]={'Group A'}>}DISTINCT [ID])

Expression for Group B is count({<[Group]={'Group B'}>}DISTINCT [ID])

Now I want to add an expression for Group A % and Group B %. I want Group A % to be the % of each Status over the total for Group A and likewise for Group B %, it would be the % of each Status over the total for Group B. Result would be:

StatusGroup AGroup A %Group BGroup B%
Active650%420%
Completed650%1680%

So essentially for Group A%, the expression would be something like:

count({<[Group]={'Group A'}>}DISTINCT [ID]) divided by the count of total [ID] for Group A


Any ideas?

1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

No need to respond. I created variables for the totals which I then used on the divisor of the expressions. At first I was exploring handling this through the expression since I had incorrectly assumed the totals from the variables would not update based on selection.

View solution in original post

2 Replies
Anonymous
Not applicable
Author

No need to respond. I created variables for the totals which I then used on the divisor of the expressions. At first I was exploring handling this through the expression since I had incorrectly assumed the totals from the variables would not update based on selection.

jaumecf23
Creator III
Creator III

Hi,

I think that also this formulas should work:

count({<[Group]={'Group A'}>}DISTINCT [ID])/count(TOTAL{<[Group]={'Group A'}>}DISTINCT [ID])

count({<[Group]={'Group B'}>}DISTINCT [ID])/count(TOTAL{<[Group]={'Group B'}>}DISTINCT [ID])