cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
tarun912
Helper IV
Helper IV

Need to display only selected ones in the chart

Hi everyone, 

I want to display only those measures in the line chart , the ones that i have selected in my slicer. Is it possible ?

Bcoz, if i select 1 slicer option then it is showing me correctly, but when I select 2 options (multi select), it is showing me all the options of the slicer in my line chart.

So, I would like to ask is it possible to show only that no. of options in the line chart that is selected in the slicer ? (say, it can be 1, 2,3...5 )


Thanks !

1 ACCEPTED SOLUTION

@tarun912 

Lets say you currently have 4 RawMeasures: A, B, C, D.

You can follow the steps: 
1. Enter Data to create a Slicer Table with a Column includes those Measure Names. 

2. Create another 4 new measures to be used in the chart based on the Raw Measures: 

 

Measure A = IF(CONTAINS('Slicer table','Slicer table'[Measures],"A"),[Raw Measure A],BLANK())
Measure B = IF(CONTAINS('Slicer table','Slicer table'[Measures],"B"),[Raw Measure B],BLANK())
Measure C = IF(CONTAINS('Slicer table','Slicer table'[Measures],"C"),[Raw Measure C],BLANK())
Measure D = IF(CONTAINS('Slicer table','Slicer table'[Measures],"D"),[Raw Measure D],BLANK()) 

 

3. Create a slicer with column in the slicer table.

select measures.JPG

Pbix file: https://qiuyunus-my.sharepoint.com/:u:/g/personal/paul_qiuyunus_onmicrosoft_com/ER5FpJFOKOVEmuNgFuZ6...


Paul Zheng _ Community Support Team
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

View solution in original post

4 REPLIES 4
V-pazhen-msft
Community Support
Community Support

@tarun912 

I am kind of confused with your question. What are the options in your slicer?

Do you mean you want to have a slicer that includes measure names that you can filter to show only selected measures in the chart?Can you explain your problem with some pictures.

 

Paul Zheng _ Community Support Team
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
  

Capture 7.PNG
For eg: I have made this slicer and A,B,C,D are four measures , So i want to display these 4 measures on a line chart . Currently I am able to display 1 measure at a time on line chart and when i multi select (for eg: 2 measures i.e A and B), then the graph will show me all the measures that are there in the slicer.
So, basically i am unable to see the number of options that i selected from the slicer ?

Thanks !

@tarun912 

Lets say you currently have 4 RawMeasures: A, B, C, D.

You can follow the steps: 
1. Enter Data to create a Slicer Table with a Column includes those Measure Names. 

2. Create another 4 new measures to be used in the chart based on the Raw Measures: 

 

Measure A = IF(CONTAINS('Slicer table','Slicer table'[Measures],"A"),[Raw Measure A],BLANK())
Measure B = IF(CONTAINS('Slicer table','Slicer table'[Measures],"B"),[Raw Measure B],BLANK())
Measure C = IF(CONTAINS('Slicer table','Slicer table'[Measures],"C"),[Raw Measure C],BLANK())
Measure D = IF(CONTAINS('Slicer table','Slicer table'[Measures],"D"),[Raw Measure D],BLANK()) 

 

3. Create a slicer with column in the slicer table.

select measures.JPG

Pbix file: https://qiuyunus-my.sharepoint.com/:u:/g/personal/paul_qiuyunus_onmicrosoft_com/ER5FpJFOKOVEmuNgFuZ6...


Paul Zheng _ Community Support Team
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

View solution in original post

AiolosZhao
Memorable Member
Memorable Member

Hi @tarun912 ,

 

You may try to change your measure like the below one:

 

IF(CONTAINS('Table (4)','Table (4)'[Month name],"June"),6,BLANK())

 

That means when the user selects "June" in the month name slicer, it shows 6, otherwise, blank().

Need to display only selected ones in the chart.PNG

 

You can see I didn't select April, so the chart don't have the value of Measure 14.

 

Aiolos Zhao

 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Power BI October Update 2021.jpg

Power BI Release

Click here to read more about the October 2021 Release!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Teds Dev Camp Oct. 2021 768x460.jpg

Power BI Dev Camp - October 28th, 2021

Mark your calendars and join us for our next Power BI Dev Camp!