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
tom_at_qunu
Frequent Visitor

Annotation of bar graph with a related descriptive value

I have margin of victory or defeat in a rugby game as "Margin".  I'm plotting "Sum of Margin" by Opposition in a bar chart, and would like to display the number of games contributing to that sum (more games agains old rivals, less against new opponents).  Can this be done?  I've considered overlaying with a Table but can't isolate the one value (Count of (MatchID).  Thanks.

2 ACCEPTED SOLUTIONS

@tom_at_qunu

I am afraid that there is no option to show the bar chart as you describe. When draging games number to Value section of bar chart, it is also easy to view the chart.



Regards,
Lydia

Community Support Team _ Lydia Zhang
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

As there appears to be no viable workaround to attain the presentation I described, I am using Tooltips to carry the number of games as "Count of MatchID" so it will appear on mouseover.  

 

Crop.png

View solution in original post

6 REPLIES 6
v-yuezhe-msft
Employee
Employee

@tom_at_qunu,

It is difficult for us to provide you suggestions or DAX formulas based on the above description, please help to post dummy data of your table and post expected result in table format.

Regards,
Lydia

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

Hi Lydia.. is this along the lines of what you asked?  This is my first post, so feeling my way along.  Thanks.

     
 OppositionOur scoreOpposition ScoreDifference 
Date1Red team15510
Date2Yellow team030-30
Date3Red Tram10010
Date4Green Team20155
Date5Red Team510-5
Date6Yellow team1055
     
   Sum of DifferenceNo. of games
  Red (10+10-5)153
  Yellow (-30+5)-252
  Green (5)51
     
 I'd like to present a horizontal bar chart conparing aggregate point differential by Opponent.
 I'd like to also present a text number between the Opponent name and the bars indicating the number of games that contribute to that sum.
   

@tom_at_qunu,

Create the following measure in your table.

No of games = CALCULATE(COUNT(Table[Opposition]))

Create bar chart as below.
1.JPG

Regards,
Lydia

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

Thanks.  I tried that along the way, but it doesn't scale well, with some of the differentials being in the hundreds, while some of the Number of games vales are ones and twos.  if you look at the paste below you'll see a space between the row headers and the bars on the graph.  I tried making a table with just Opposition and the number of games, with the intent to overlay the graph to properly locate the text number in the white space, but I can't get rid of the "Opposition" column.  is there a way to do that (keep only the column of values in the display)?  I appreciate your continued help.

 

Snippet2.png

@tom_at_qunu

I am afraid that there is no option to show the bar chart as you describe. When draging games number to Value section of bar chart, it is also easy to view the chart.



Regards,
Lydia

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

As there appears to be no viable workaround to attain the presentation I described, I am using Tooltips to carry the number of games as "Count of MatchID" so it will appear on mouseover.  

 

Crop.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.