Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hey,
I am looking for a way to create a bar chart which has two measures and two dimensions.
Currently my chart has one measure but I would also like to add the target beside the current chart. I have had a look through the forums but cant see anything where two measures and dimensions can be combined.
Current:
Chart done in excel which I'm trying to replicate.
Thanks,
Tom
Yes this is achievable
Dimension 1 : X - Axis , Just combine your dimensions using a calculated dimension
Aggr(MonthYear&'-'&Type,MonthYear,Type) << Assuming Type field has values Target & Achieved
Dimension 2: simply the dimension values you want to see stacked
Measure = Sum(Sales)
you actually need to take it one step further. instead of AGGR in the dimension, you should create a dual which is the concat of the month and type (target or actual) and the number part which allows you to sort it properly. if you dont youll have a hard time ordering JAN, FEB, MAR...
also in the dim you dont need the aggr. you will get the same result. what is key here is the color:
for example i used DIM - A,B,C:
=if(type='TARGET',pick(match(dim,'A','B','C'),ARGB(100,200,0,0),ARGB(100,0,200,0),ARGB(100,0,0,200)),
pick(match(dim,'A','B','C'),ARGB(200,200,0,0),ARGB(200,0,200,0),ARGB(200,0,0,200)))
but you should be able to find a more dynamic way of assigning color and alpha value
"if you dont youll have a hard time ordering JAN, FEB, MAR.."
You can sort by expression
under sorting >> sort by Expression >> =MonthNum