Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hey folks,
Trying to learn about set analysis by working on a KPI element.
To illustrate I made some sample data:
Brand | Model | Measure |
---|---|---|
x | a | 1 |
x | a | 2 |
x | b | 3 |
y | c | 4 |
y | c | 5 |
y | c | 6 |
I want to create a KPI that shows the "percentage of subtotal" based on what brand or model I select. So if I select "Model=b" I want the KPI to show the percentage of subtotal for brand x. ie 3/6=50% but so far I have only been able to figure out how to calculate the percentage of the TOTAL for all brands giving me 3/21=14% using Sum(Measure)/Sum({1}Measure)
Any ideas from you clever people?
/Andreas
Try this:
Sum(Measure)/Sum({<Model, Brand = p(Brand)>}Measure)
Maybe like
Sum(Measure)/Sum({<Model=, Brand=p()>} Measure)
You may also create straight table with dimension, brand and model, and expression, SUM(TOTAL<Brand,Model>Measure)/SUM(TOTAL<Brand> Measure) to show KPI for all brand/model in the table together.
Hi Andreas,
What about this pivot table with expression: Sum(Measure)/Sum(TOTAL <Brand> Measure) ?
Model | Brand | x | y |
---|---|---|---|
a | 50% | - | |
b | 50% | - | |
c | - | 100% |
Cheers
Andrew
Thanks a lot for the replies guys! The p() function did the trick this time.
/Andreas