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
RafaelKnuth
Advocate I
Advocate I

Displaying values underneath each bar on the X-axis

I want to show the number of 911 calls by the hour (the data has been aggregated over 3 months). I am using a publically available data set from Kaggle, just for the record.

I selected a ribbon chart with the time (24h format) and number of support calls as the value.

 

Capture2.JPG

 

The only thing I would like to change is the increment from 5 to 1, so that every single hour is displayed underneath each bar. I can't see how I can change the increment. Changing the size of the chart (as some users are suggesting in other threads) does not do the trick.

I coulnd’t figure out how to change the increment, so I've then changed type from Continous to Categorical, which increments by 1 and displays every single hour underneath each bar as desired, but only in reversed order. I can't change from descending to ascending, which forces one to read the chart from the right to the left. Very frustrating.

 

Capture.JPG


I've tried the triple dotted Icon next to my chart, and I can only sort Z to A, but not A to Z. I do not see that down arrow icon right to Sort by time. Any ideas? Thanks!

 

UPDATE

 

I found a workaround which does the trick. First, I created an index column that runs in reversed order to my 24hr count.

 

Capture4.JPG

 

Next, I clicked on my time column under Fields and then I switched from time (default) to Index under Modeling > Sort by Column. Oh, by the way, I added 911 call categories to my chart legend.

 

Capture5.JPG

 

It's beyond my comprehension why I can only sort in descending order (Z to A) but ... be that way. I downloaded the latest desktop version of Power BI today, but weirdly, some other versions (obviously previous ones) seem to have a sort A to Z as well as Z to A sorting feature which can be changed clicking on the down arrow (as you can see in my screenshots above, I do not have a down arrow next to my sort Z to A).

 

The devil is in the details, as the saying goes. And this is a very nasty one which cost me an entire day. Very annoying.

1 ACCEPTED SOLUTION

Hi

I follow the steps as you said, however, I don't face the same problem as you did.

Here is my pbix.

Please click more times on the "Sort By TimeStamp".

 

Best Regards

Maggie

View solution in original post

3 REPLIES 3
v-juanli-msft
Community Support
Community Support

Hi

Thank you for sharing such detailed information with us, it also prompts me to do a test with my Version: 2.58.5103.501 64-bit (May 2018).

 

In this situation, time is sort from 23 to 0, and I see “sort Z to A by time”.

 11.jpg

After clicking on “sort Z to A” above, time is sort from 0 to 23, and I see “sort A to Z by time”.

 12.jpg

 

“I can only sort Z to A, but not A to Z. I do not see that down arrow icon right to Sort by time”

How about clicking on the “sort Z to A” of your second picture, it does not work to show correct order?

 

Best Regards

Maggie

Hi Maggie,

 

thanks for your reply. I am using the same build Version: 2.58.5103.501 64-bit (May 2018).

Since we are using the same version, it might be that Power BI handles my data set differently, as I had to do some fairly complex cleansing and manipulations on my dataset.

 

That being said, I created a simple table with a time stamp (TimeStamp column) 0 to 23 and some arbitrary values (Volume column) for each hour.

 

Capture.JPG

 

 

Next, I loaded that table into Power BI, and I ran into exactly the same issues as described in my initial post.

I created a ribbon chart, then I dragged and dropped my TimeStamp on the Axis and Volume on the Value field.

Hours increment by 5 (0, 5, 10, 15, 20) and I can't change the increment to 1. So, I changed Type from Continuos to Categorical which displayed my chart exactly as shown in your first screenshot. But then, again, I was only able to sort Z to A. No other option available.

 

Capture2.JPG

 

Since we are using the same build and you are able to sort bi-directionally and I can't - maybe I am missing something here. Can you take a look at the walkthrough above if I am maybe making a mistake I am not aware of which disables bi-directional sorting? Thanks.

 

Best,

 

Raf

Hi

I follow the steps as you said, however, I don't face the same problem as you did.

Here is my pbix.

Please click more times on the "Sort By TimeStamp".

 

Best Regards

Maggie

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.