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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
crawfe
Helper I
Helper I

Variable Y axis scale based on slicer?

Hi. I ama relatively new user....Is there a way to set the Y axis scale of a bar/line chart, based on a slicer choice? I have widely varying data maximums based on a slicer. I could leave the scale auto but I need my bar and line to use the same axis values (for example a data bar and a target line). Is there a way to set the scales to be the same AND vary by slicer? 

  I hope this is a good enough description. A solution for either aspect would be appreciated..Thanks! 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@crawfe , there is no option to set the Y-axis scale by a measure or variable. Automatic is just an option that can reset the scale based on changes

View solution in original post

5 REPLIES 5
mahoneypat
Employee
Employee

You could use the value of a slicer in a measure where you divide your original result by the slicer value and turn your Y axis into % of slicer value.  If you then fix the Y axis to a max of 1, you would get a zoom in effect with slicer changes.

Regards,

Pat





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


I am not sure that I could use that view but clever! 

amitchandak
Super User
Super User

@crawfe , there is no option to set the Y-axis scale by a measure or variable. Automatic is just an option that can reset the scale based on changes

OK Too bad. Thanks. Why is there no way to select an option to sync the Y and Y2 axes? That option has been requested for years and seems pretty straightforward. 

I didn't find a way to explicitly set the Y and Y2 axes to sync, but I found that if I turn off Secondary axis (and title) and set the Y2 axis scale to auto-auto (Both needed!), and the Y axis to 0-Auto, the Y2 axis seems to track the Y axis. So this gets me past the slicer big difference problem. Thanks for giving it thought! 

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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