2 Replies Latest reply on Aug 2, 2012 7:53 AM by Mark Holtz

    Visualizing Different Measure in Groups

      I am fairly new to Tableau, so this may be a basic question. I am working 1 Dimension, Quarter, with 4 measures:

      Money Market Deposit

      Time Deposits

      Other Saving Deposits

      Transaction Deposits


      The first three measures belong to a group: Non transaction Deposit. I can create a calculated field NontransactionDeposit = Money Market + Time + Other. And then put Transaction and Non transaction on a dual axis to get a stacked bar, but then I lose information about the composition of Non transaction into its sub categories. Ideally, I would like a stacked bar with each of the four measures


      Any thoughts on how foes about this?




        • 1. Re: Visualizing Different Measure in Groups
          Mark Holtz

          You could turn your 4 measures into a single dimension and then make a single measure of "Deposits":


          For your "Type" dimension it'd be something like this:

          IF [Money Market Deposit] <>0 THEN 'Money Market'

          ELSEIF [Time Deposits] <> 0 THEN 'Time'

          ELSEIF [Other Saving Deposits] <> 0 THEN 'Other Saving'

          ELSEIF [Transaction Deposits] <> 0 THEN 'Transaction Deposits'

          ELSE 'Unhandled'

          //should not get any "Unhandled" results



          Then your Deposit Amount measure would be:

          [Money Market Deposit] + [Time Deposits] + [Other Saving Deposits] + [Transaction Deposits]



          This way, you only have a single measure and your dimension can be used for grouping, sorting, coloring, etc.(Even if it "resides" in the Measures section in the Tableau Data Window.)


          Further, you can create an addition Trans/Non dimension then that can group your new "Type" dimension like this:

          IF [Type] = 'Transaction Deposits' THEN  'Transaction Deposits'

          ELSE  'Non Transaction Deposits'


          • 2. Re: Visualizing Different Measure in Groups
            Mark Holtz

            Actually, I may have misunderstood how your data is structured.

            If your underlying data already has data aggregated into quarters, then you probably cannot do what I described above because you likely have non-zero totals in each quarter.


            I was assuming you had transaction-level data.


            If you only have quarter-level data with 4 columns of figures that you wish to create into a stacked bar, you could just drag the measures values on the rows shelf, and drag the Measure Names to the color shelf...


            I've attached a workbook to illustrate