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
GrimReaperX
Helper II
Helper II

Making shadowed stacked column chart with slicers

Hello guys, 

I am trying to figure out how to create a stacked column chart reflecting a shadow connected dynamically with slicers ? I've seen it in the Gartner Life Expectancy dashboard which is as below. Any idea how to create this kind of dynamic column chart without using selection pane ? 

GrimReaperX_0-1654093943757.png

Link as follows (Gartner Analytics and BI Virtual Bake-Off 2020: world population health analysis with Power BI - You...)

Thank you.

 

1 ACCEPTED SOLUTION

Hi @GrimReaperX ,

You can apply different colors on the chart based on your condition, for example in my sample, I modify the color formula like this:

Measure =
IF (
    MAX ( 'Table'[Column1] ) >= MAX ( 'Table 2'[Column1] ),
    "Grey",
    IF (
        MAX ( 'Table'[Column1] )
            >= MAX ( 'Table 2'[Column1] ) - 5,
        "Orange",
        "Blue"
    )
)

Get the result. But in the slicer, the text can't be hided, it's by design.

vkalyjmsft_0-1654566950506.png

I attach my sample below for reference.

 

Best Regards,
Community Support Team _ kalyj

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

3 REPLIES 3
v-yanjiang-msft
Community Support
Community Support

Hi @GrimReaperX ,

According to your description, I create a sample.

vkalyjmsft_0-1654499628418.png

In the column chart, Column1 is in the Axis. Here's my solution.

1.Create a new table, don't make relationship between the two tables.

 

Table 2 = VALUES('Table'[Column1])

 

2.Create a measure.

 

Measure = IF(MAX('Table'[Column1])>= MAX('Table 2'[Column1]),"Grey","Blue")

 

3.In the column chart formatting pane>Columns>Colors, click the fx button.

vkalyjmsft_1-1654500083258.png

Select the new measure in the color formatting based on field.

vkalyjmsft_3-1654500380115.png

4.Put the column from the new table in a slicer, get the result.

vkalyjmsft_4-1654500572214.png

I attach my sample below for reference.

 

Best Regards,
Community Support Team _ kalyj

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

Hi @v-yanjiang-msft ,

 

Thanks for your answer, i greatly appreciate that. Is it also possible to apply different colors on the chart based on different buckets? As you can see from the picture that i shared in first post, there is different colors for specific range.

 

Moreover, is it possible to hide section below in the slicer? I just want to have slicer itself without any text. 

GrimReaperX_0-1654514544381.png

 

Thank you very much.

Hi @GrimReaperX ,

You can apply different colors on the chart based on your condition, for example in my sample, I modify the color formula like this:

Measure =
IF (
    MAX ( 'Table'[Column1] ) >= MAX ( 'Table 2'[Column1] ),
    "Grey",
    IF (
        MAX ( 'Table'[Column1] )
            >= MAX ( 'Table 2'[Column1] ) - 5,
        "Orange",
        "Blue"
    )
)

Get the result. But in the slicer, the text can't be hided, it's by design.

vkalyjmsft_0-1654566950506.png

I attach my sample below for reference.

 

Best Regards,
Community Support Team _ kalyj

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

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.