2 Replies Latest reply on Aug 14, 2018 11:18 AM by ulrike.keler

    Stacked bar for information from different measures

    ulrike.keler

      Hi,

       

      I would like to visualize the remuneration of our employees in a way that shows the fixed part and the variable part as a stacked bar.

      I have two measures:

       

      1. fixed income per year

      2. variable income per year

       

      I created a new calculated measure that adds both parts to give me the total yearly income. But this way I lose the information about how the income is composed.

       

      Any idea how I could get a bar that shows the total income as well as the parts that it consists of (fixed and variable)?

       

      Thanks!

        • 1. Re: Stacked bar for information from different measures
          Ankit Bansal

          Ulrike,

           

          So currently you have data something like this:

           

          empno , fixed , variable

          1               100     50

          2               200     30

           

          You need to pivit your data as below

           

          emp no          salary salary_type

          1                    100     fixed

          1                      50     variable

          2                    200     fixed

          2                      30     variable

           

          You can do this in data source pane by selecting 2 measures , right click and choose pivot.

           

          Now you just need to put emp no on row shelf, salary on column shelf and drag salary type to color to get stacked bar chart.

           

          Hope it helps.

           

          Thanks,

          Ankit Bansal

          2 of 2 people found this helpful
          • 2. Re: Stacked bar for information from different measures
            ulrike.keler

            Thank you Ankit, works great!