7 Replies Latest reply on Aug 7, 2018 1:15 AM by S Kailay

    How to create a heat map grid

    S Kailay

      Hi all,

       

      I have a list of 100 unique entities which are rated either Low, Medium-Low, Medium-High or High (workbook attached).

       

      I'm trying to create a 10x10 grid with each square denoting an entity and its rating based on a colour i.e. Low = green, Mdeium-Low = yellow, Medium-High = Orange and High = Red.

       

      Is there any way of doing this?

       

      Thanks!

       

      Sandeep

        • 1. Re: How to create a heat map grid
          Ken Flerlage

          You'll need a few calculated fields to work out the positions on the grid, as follows:

           

          Index

          // Allow us to assign a number to each entity.

          INDEX()

           

          Row

          // Which row will this be placed on?

          INT(([Index]-1)/10)+1

           

          Column

          // Which column will this be placed on?

          (([Index]-1)%10)+1

           

          Now do the following:

           

          1) Drag Entity to the Detail card

          2) Drag Rating to the Color card.

          3) Drag Column to the columns shelf and Row to the rows shelf.

          4) Change both pills to Discrete.

          5) Because of the use of INDEX(), these will be table calculations. Right-click on each and choose Edit Table Calculation and set them as follows:

           

          You should now have something like this:

           

           

          From here, you can resize the columns and rows, remove the headers, and increase the size of the squares to get something like this:

           

           

          See attached workbook.

           

          If this resolves your issue, please be sure to mark this as the "correct answer" so we can close this thread and others can learn from it in the future.

          1 of 1 people found this helpful
          • 2. Re: How to create a heat map grid
            S Kailay

            Hi Ken,

             

            This is great!

             

            Two quick questions if I may:

             

            1. Is there any way to sort the squares based on the rating? I.e all the

            high ratings together, followed by medium- high etc?

            2. What would you recommend as the best way to show changes in rating? E.g

            if there are 10 rating changes during a month?

             

            Thanks,

             

            Sandeep

            • 3. Re: How to create a heat map grid
              Ken Flerlage

              1) Create a new calculated field, which will allow us to sort it.

               

              Rating Order

              // Allow us to sort by rating highest to lowest.

              CASE [Rating]

              WHEN "High" THEN 1

              WHEN "Medium-High" THEN 2

              WHEN "Medium-Low" THEN 3

              WHEN "Low" THEN 4

              END

               

              Change this to a dimension, then drag it to the detail card. Finally, change the table calcs as follows:

               

               

              See attached workbook.

               

              2) There are a number of different approaches you could take here. Are you looking to just show the number of changes in a month or the ratings of each of those changes? Are you looking to show multiple months or just one? Do you have any sample data with this additional information in it?

              1 of 1 people found this helpful
              • 4. Re: How to create a heat map grid
                S Kailay

                Hi Ken,

                 

                This is fantastic - thank you so much for your help!

                 

                In terms of question 2, I'm just looking to show the changes over 1 month.

                Specifically, the total number of changes and then a simple table of those

                changes showing the previous rating and the current rating.

                 

                Cheers,

                 

                Sandeep

                 

                On Fri, 3 Aug 2018, 17:39 Ken Flerlage, <tableaucommunity@tableau.com>

                • 5. Re: How to create a heat map grid
                  Ken Flerlage

                  Would probably need to see some data with that information in it. Perhaps we should close this thread and open a new one?

                  • 6. Re: How to create a heat map grid
                    S Kailay

                    Hi Ken,

                     

                    That's a good idea - I'll close this thread shortly and create a new one

                    under a title of non-numerical calculations.

                     

                    Regards,

                     

                    Sandeep

                     

                    On Sat, 4 Aug 2018, 00:38 Ken Flerlage, <tableaucommunity@tableau.com>

                    • 7. Re: How to create a heat map grid
                      S Kailay

                      Hi Ken,

                       

                      I've opened a new thread called Non-numerical Calculations to address my

                      outstanding query.

                       

                      It would be great if you could take a quick look.

                       

                      Thanks!

                       

                      Sandeep