Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
newpi
Helper V
Helper V

Stacked column and line chart view showing unselected users on the X axis

Hi,

 

I have an average of average formula which correctly calculates average between  groups or users. My problem is when I use this formula and select only 2 or few users out of 9, it is showing value bars for those selected users but it is showing all other UNSELECTED USERS as well on the 'X' axis with blank values. I want to just show the selected users on my X axis and their corresponding avg line .

 

My formula is 

Avg Hours / Day (Team)  =
CALCULATE(AVERAGEX(VALUES('Table Name'[User Name]),[Avg Hours / Day]) ,ALLNOBLANKROW('Table Name'[User Name])) 

or
Avg Hours / Day (Team) = 
AVERAGEX(SUMMARIZE('Table Name','Table Name'[User Name],"_1", [Avg Hours / Day]),[_1])
 
Only user name is a column value in the above formulaes and avg hours/day is a DAX measure
 
Both the formulas work in calculating the average of average correctly but I do not want unselected users to appear on my axis. 
 
Below is a screenshot of how it looks. I have a group selected in my slicer on the top. Would greatly appreciate a solve for this.
Screen Shot 2020-08-14 at 10.49.49 PM.png
 
 


 
 

 

1 ACCEPTED SOLUTION

Hi , @newpi 

You can take a try to create a visual control measure.

Something as below:

 

Country visual control = IF([Avg **** Hours / Day]=0,0,1) 

 

Then drag this measure to visual filter pane as below,then apply it

95.png

 

Best Regards,
Community Support Team _ Eason
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

6 REPLIES 6
Ashish_Mathur
Super User
Super User

Hi,

Does this measure work?

=IF(ISBLANK([Avg Hours / Day (Team)]),BLANK(),[Avg Hours / Day (Team)])

If it does not, then share the link from where i can download your PBI file.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

@Ashish_Mathur The measure is not working. Its still selecting all unselected users. I'm not sure if I Can share the PBIX file since its company data, any other way to do this?

Hi , @newpi 

You can take a try to create a visual control measure.

Something as below:

 

Country visual control = IF([Avg **** Hours / Day]=0,0,1) 

 

Then drag this measure to visual filter pane as below,then apply it

95.png

 

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

@v-easonf-msft Thanks. This was really helpful. Was struggling with this since a week. It worked perfectly in combination with other's solution here. @pranit828 

pranit828
Community Champion
Community Champion

Hi @newpi 

 

It has to do with how the interactions is configured.

 

Goto format --> Interactions

pranit828_0-1597464954369.png

 

Click on user selection pane.

 

On top of the chart, which you need filtered , you will see the below icons popup.

pranit828_1-1597465037504.png

Select the one which is highlighted above.

 

Did I resolve your issue? Mark my post as a solution!

 

Appreciate your Kudos, Press the thumbs up button!!

 

Regards,
Pranit

 

 





PBI_SuperUser_Rank@1x.png


Hope it resolves your issue? 
Did I answer your question? Mark my post as a solution!

Appreciate your Kudos, Press the thumbs up button!!
Linkedin Profile

@pranit828 I can't see the icon in the middle when I try to edit interaction. I only the the first and 3rd icon . Attached imgScreen Shot 2020-08-15 at 11.12.07 AM.png

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.