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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
powerboss
Frequent Visitor

How To Change X-Axis Labeling

So I created this thread: https://community.powerbi.com/t5/Desktop/How-To-Differentiate-2-Different-Items-On-Line-Chart-With-S...

 

My main problem now is the X-axis looks very muddy. Is there a way I can just have the years in intervals, i.e. "2015", "2016", then "2017", etc...

 

Thank you. 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

HI @powerboss,

It sounds like you want to group your axis label based on category fields. If this is a case you can enable this effect by modifying the x-axis type to 'categorical' and turn off the 'concatenate label' option. (notice: don't forget to set 'sort by' current axis fields to enable axis grouping)
Regards,

Xiaoxin Sheng

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

HI @powerboss,

You can write a measure with some variables to stored extract current category and year, then you can use them to find out previous records. 

After these, you can aggregate table records that filter by above parameters and compare/calculate between different values.

In addition, I'm not so clear for your table structure, can you please share some dummy data and expected results for test?

How to Get Your Question Answered Quickly 

BTW, you can also take a look at the following blog about custom soring:

Custom Sorting in Power BI 

Regards,

Xiaoxin Sheng

rajulshah
Resident Rockstar
Resident Rockstar

Hello @powerboss,

 

Can you please provide the image so that I can understand the issue clearly?

I am limited in how much I can share, however for this X-axis I drilled down to include two categories: the date and the order number. 

 

Right now it looks like this: 

 

muddy axis.PNG

 

I need to include the order# in the drill down category in order to separate it, however it now includes it in the x-axis labeling, making it look terrible. 

 

Any ideas? 

Anonymous
Not applicable

HI @powerboss,

It sounds like you want to group your axis label based on category fields. If this is a case you can enable this effect by modifying the x-axis type to 'categorical' and turn off the 'concatenate label' option. (notice: don't forget to set 'sort by' current axis fields to enable axis grouping)
Regards,

Xiaoxin Sheng

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors