2 Replies Latest reply on Jun 20, 2016 6:32 AM by joyce.chapman

    Visual ranking by category: sorting, ranking, and filter help


      Hello! I'm new to Tableau and to the forums. This is my first post, and I'm attaching a workbook. I've tried to reproduce this functionality from the Data Revelations blog. In my dashboard, the user should select a question from a filter, that question should appear as a bar chart, then they should be able to select a facet from another filter to explore the data by. When they click any bar in the top chart, they will see a second bottom chart appear showing where the categorical item ranks in each group. Three things appear to not be working properly in the dashboard (see attachment): 


      1. Sorting: how do I get each question when selected to sort itself in descending order in the top chart (as well as the bottom chart, once it appears)? Right now the question that I sort in the worksheet is correctly sorted in the dashboard, but any other question selected is not sorted.

      2. Ranking: the example on the blog has the results within each category in the bottom chart sorted and ranked from largest to smallest. In my bottom chart, while the bars are correctly sized the results are not resorted or reranked. The ranking appearing is the ranking from the top chart, and all categorical answers are in the same order instead of appearing where they should based on descending order in the rank of their particular group.

      3. Filter: the whole set up is only working for one of my four questions, "Library staff are considering...". If that question is selected, the highlighting and second chart works; if any other question is selected, the bottom chart will not appear and selecting any bar in the top chart does nothing.


      I hope I've explained the issues intelligibly, my Tableau "lingo" is not advanced. Thank you for any assistance!

        • 1. Re: Visual ranking by category: sorting, ranking, and filter help



          Welcome to the Forums.

          Well done on the worksheets, quite a lot of moving parts.

          It is pretty much all there, I think it needs just a few tweaks:

          1. To get the top chart to sort descending percentages:

              a. Changing Sort of [Rank] to "Data source order"

              b. Changing Sort of [Data] to "Sort by" and "Field: Number of Records" and "Aggregation: Sum" and "Sort Order: Descending"

          2. To get bottom charts to sort:

              a. Changing [Rank] to work on the Sum of records: RANK_UNIQUE(SUM([Number of Records]))

          3. To get the bottom sheets for all Questions

              a. Adding [Question super wording] to the Detail Shelf of sheet practice2c

              b. Editing the Show-Hide Filter to add to "Target Filters" to add the Filter of [Question super wording]


          I may have missed some things, but I hope the attached can be a first step to solving.

          Would be happy to try and explain aspects further, if needed.


          2 of 2 people found this helpful
          • 2. Re: Visual ranking by category: sorting, ranking, and filter help

            Thank you so much, and for sending the example file! This works.