Forum Discussion

arolon2's avatar
arolon2
Frequent Visitor
5 years ago
Solved

Matrix visual coloring by column

Hello,

 

I have a current matrix visual that I'm trying to make easier on the eyes. The crux of the issue is that I am looking to either apply a background color to alternateing months (in the pic below July and September 2021). In lue if that apply the background color to just the Lag_0 values of each month.

 

What I have:

What I'm looking for:

Or:

  • Hi arolon2,

     

    Please try conditional formatting as:

    If you still have some question, please don't hesitate to let me known.‌‌

     

    Best Regards,

    Link

     

    Is that the answer you're looking for? If this post helps, then please consider Accept it as the solution. Really appreciate!

3 Replies

  • arolon2 you can add a new measure for color and apply it as a background color for your value:

     

    Background Color = IF ( SELECTEDVALUE ( YourTable[Lag Coloumn] ) = "Lag_0", "Yellow" )

     

    instead of yellow, you can also use hex color code.

     

    Follow us on LinkedIn

     

    Check my latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would  Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!

     

    Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.

    • arolon2's avatar
      arolon2
      Frequent Visitor

      So I created the following measure 

      Background Color = IF(
          SELECTEDVALUE(Combined_Lag[Lag]) = "Lag_0", "#82e0ff"
      )

       

      I tried to apply it to the background color below but it did not reflect on the visual.

       

       

  • v-xulin-mstf's avatar
    v-xulin-mstf
    Community Support

    Hi arolon2,

     

    Please try conditional formatting as:

    If you still have some question, please don't hesitate to let me known.‌‌

     

    Best Regards,

    Link

     

    Is that the answer you're looking for? If this post helps, then please consider Accept it as the solution. Really appreciate!