Forum Discussion

Unicorn_Tech's avatar
Unicorn_Tech
Resolver I
5 years ago
Solved

Conditional Formatting based on time

Apologies if this is a duplicate post.


I would like to set up conditional formatting, comparing one value in a column to another value in a column (for the same row.)  I want to know if Monthly Average Time on a Page is larger than the Yeary Average Time on a Page.

 

Sample table:

PageMonthly AverageYearly Average
Home Page01:3201:28
about Page00:5201:20

 

Ideally, for the above table, the Monthly Average for "Home Page" would be bold, and the Yearly Average for "About Page" would be bold.

 

This is more complicated because this is a time value.  I'm assuming I would have better luck using the raw decimal data to do the comparison of greater than?  The above is correct, but it's formatted to show a correct value.

  • Unicorn_Tech  Can you please try doing it below if helps you.

     

    Change the time value to below

     

    then create one measure like 

    Check = if (SUM(Page[Yearly Average])>SUM(Page[Monthly Average]),1,0)
     
    then set the rules like below for both monthly average and Yearly Average

    below is the ouput

     

2 Replies

  • negi007's avatar
    negi007
    Community Champion

    Unicorn_Tech  Can you please try doing it below if helps you.

     

    Change the time value to below

     

    then create one measure like 

    Check = if (SUM(Page[Yearly Average])>SUM(Page[Monthly Average]),1,0)
     
    then set the rules like below for both monthly average and Yearly Average

    below is the ouput