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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
DavSam
Frequent Visitor

Y-axis label of non-selected bar chart being displayed when filtering/slicing

DavSam_2-1683502638551.png

 

I am a newbie to  Power Bi so any help would be greatly appreciated.

I have two bar charts from 2 different data sources that have been linked to a date table. I then applied a filter so I can choose to display particular bar charts. 

I am now completely stuck on the last hurdle! Even though the data in the non-selected bar chart is not displayed, its y-axis label still appears, i.e. 'Dec 2021'.

How do I remove this y-axis label but still have it appear when Dec 2021 data is selected for display?

Thanks

 

 

 

1 ACCEPTED SOLUTION
DavSam
Frequent Visitor

Hi Rita I have figured out how to represent bars as percentages for each category. I hot encoded my results column a to pass and fail and then I created a Dax formula to calculate percentage pass and fail rates. So my bar chart works.

Thanks for the guidance about merging my data sources together.

View solution in original post

5 REPLIES 5
DavSam
Frequent Visitor

Hi Rita I have figured out how to represent bars as percentages for each category. I hot encoded my results column a to pass and fail and then I created a Dax formula to calculate percentage pass and fail rates. So my bar chart works.

Thanks for the guidance about merging my data sources together.

DavSam
Frequent Visitor

Date of examResultWhite Black 
01/01/2020Fail10
01/01/2020Fail01
01/01/2020Fail10
01/01/2020Fail10
01/01/2020Fail10
01/01/2020Fail10
01/01/2020Pass10

 

Date of exam ResultBlackWhiteOtherAsianUnknown
30/12/2021Pass10000
30/12/2021Fail01000
30/12/2021Pass00100
30/12/2021Pass00010
30/12/2021Pass10000
30/12/2021Pass01000
30/12/2021Pass00001

 

Date
01/04/2020
02/03/2021

 

Hi, I am completely new to Power BI, but have managed to get quite far with constructing percentage bar charts to show ethnicity data for two different exam sittings. My data sources consist of three tables. The two exam sitting data are linked to the date table so that I can use the filter card to display specific exam dates for the bar charts. I have been able to construct bar charts that show the percentage of each ethnic group and whether they pass or fail, so I have no problem with producing the charts in Power BI.

 

But when I apply my filter card as demonstrated below. The y-axis label remains for the lower bar chart which I don't want my users to see. If I set Y-axis label to Auto it does disappear but I want to give the Y-axis a specific label so do not want to set it to Auto.

I would be grateful for any guidance and help.

Thanks

 

 

issue 1.png

DavSam
Frequent Visitor

Hi Rita, I should have been clearer the bars should show the percentage of candidates who obtained a pass in a particular time period for each ethnic group. So the bar height for white candidates who pass in January 2020 should be 16.7% as 1 white candidate out of a total of 6 white candidates passed. This is why I original hot encoded my ethnic group data so that I could sum the columns for each ethnic group and complete % amount calculations

Hi @DavSam 

Graph axis titles can't be activated based on your date selection.
To show only what you selected, the two sets should appear on one graph.
The picture shows how it looks

Ritaf1983_0-1683601856098.png

Ritaf1983_2-1683603098630.png

 

To make everything fit on one graph, you have to arrange the tables and union them with PQ.

It must be one big vertical table, no small horizontal tables, or you won't be able to do comparative analyses

Ritaf1983_1-1683602397193.png

Here are some links to learn what you need to do and also my sample file so you can see what I did.
unpivot table to make it "vertical" :

https://www.youtube.com/watch?v=laELUZvyd2w

union tables:
https://www.youtube.com/watch?v=qkmcVHHdQPY

Sample File 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile
Ritaf1983
Super User
Super User

Hi @DavSam 
Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).
https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-...
Please show the expected outcome based on the sample data you provided.

https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors