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
GunnerJ
Post Patron
Post Patron

Can't show legend in my line chart

I'm wanting to show a simple line chart that shows the values for each user month after month. Along with those values I want to have a line that shows the average so we can easily see who is over/under performing. My issue is that if I put the names column in the legend space I can't place my average calculation and if I place my average calculation in the values or secondary values space I can't use the legend anymore. Is there a way around this? 

 

In the picture below you can see the visual with the legend in place but the calculated column "Average Value" is not able to go in the values or secondary values space.

 

I'm guessing the issue is that the average calculation doesn't have an associated "Name" for the legend but hoping there's a solution. Thank you!

 

legend.PNG

1 ACCEPTED SOLUTION
V-lianl-msft
Community Support
Community Support

Hi @GunnerJ ,

 

The visual with legend field does not support adding multiple values at present. Please try to create multiple measures.

V-lianl-msft_0-1622181403051.png

a = CALCULATE(SUM('Table'[value]),'Table'[Type]="a")
b = CALCULATE(SUM('Table'[value]),'Table'[Type]="b")
c = CALCULATE(SUM('Table'[value]),'Table'[Type]="c")
average_ = AVERAGE('Table'[value])

 

Best Regards,
Liang
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

2 REPLIES 2
V-lianl-msft
Community Support
Community Support

Hi @GunnerJ ,

 

The visual with legend field does not support adding multiple values at present. Please try to create multiple measures.

V-lianl-msft_0-1622181403051.png

a = CALCULATE(SUM('Table'[value]),'Table'[Type]="a")
b = CALCULATE(SUM('Table'[value]),'Table'[Type]="b")
c = CALCULATE(SUM('Table'[value]),'Table'[Type]="c")
average_ = AVERAGE('Table'[value])

 

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

 

Pragati11
Super User
Super User

Hi @GunnerJ ,

 

May be try using other visual like Line and Clustered Column chart and then use SMALL MULTIPLES. Somehting like below:

Pragati11_0-1622039259954.png

 

Thanks,

Pragati

 

Best Regards,

Pragati Jain


MVP logo


LinkedIn | Twitter | Blog YouTube 

Did I answer your question? Mark my post as a solution! This will help others on the forum!

Appreciate your Kudos!!

Proud to be a Super User!!

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.