3 Replies Latest reply on Aug 4, 2017 4:55 PM by Ray Givler

    Pie chart with one dimension and two measures.

    Shreya Gupta

      Hi,

       

      I have one dimension of hotel with 5 hotels in it.  I want to make a pie chart with value total cost spend and color the sectors using below field:

      IF [Delta Fraud Decline Rate]>0 and [Delta fraud rate]>0 then 'green'

      ELSEIF [Delta Fraud Decline Rate]>0 and [Delta fraud rate]<0 then 'blue'

      ELSEIF [Delta Fraud Decline Rate]<0 and [Delta fraud rate]>0 then 'red'

      ELSEIF [Delta Fraud Decline Rate]<0 and [Delta fraud rate]>0 then 'yello'

      END

       

       

      Can someone please help me

        • 1. Re: Pie chart with one dimension and two measures.
          Ray Givler

          That might get a bit cryptic because your pie colors are going to map to a color description, which won't tell your customer much. I'd suggest this:

           

          IF [Delta Fraud Decline Rate]>0 and [Delta fraud rate]>0 then 'Rate + / Decline +'

          ELSEIF [Delta Fraud Decline Rate]>0 and [Delta fraud rate]<0 then 'Rate - / Decline +'

          ELSEIF [Delta Fraud Decline Rate]<0 and [Delta fraud rate]>0 then 'Rate + / Decline -'

          ELSEIF [Delta Fraud Decline Rate]<0 and [Delta fraud rate]<0 then 'Rate - / Decline -'  <-- note that your condition needs to change here to [Delta fraud rate]<0

          END

           

          Drag this to Rows, total cost to Columns, then click Show Me | Pie Icon. Then click on your colors in the legend to change them. You can drag them to the order you want and Tableau will rearrange the wedges in the pie.

          2 of 2 people found this helpful
          • 2. Re: Pie chart with one dimension and two measures.
            Shreya Gupta

            I will signify all the required details in the labels. This is just one half of the dashboard.
            I need the view as above.

             

            Can you please help with that.

            2 of 2 people found this helpful
            • 3. Re: Pie chart with one dimension and two measures.
              Ray Givler

              Do the prior steps and drag hotels to rows. That will give you a pie chart for each. If that's not what you want, please elaborate. It's not clear from your original post or the follow up.

              2 of 2 people found this helpful