Forum Discussion

Nico_Schulze's avatar
Nico_Schulze
Frequent Visitor
3 years ago

secondary y-axis

Hello all,

does anyone know if it is possible in Power Bi to create a chart with two bars that have a second y-axis? I am only shown the combination of bar chart and line chart, but I would like to have two bar charts as shown in the example below.

I would be very grateful for an answer!

Many greetings
Nico

 

ā€ƒ

7 Replies

  • Dear Nico,

     

    Good Day!

    You can do with Custom visual (Lipstick Column Pro) Bar chart. There are many types of bar Charts are available...

     

     

    Thank you!

     

    Sandeep

  • Nico_Schulze's avatar
    Nico_Schulze
    Frequent Visitor

    Hello,

    thank you very much for your answers. That definitely helped me, however I need the diagram with the possibility to have two y-axes. Do you know if this is possible?

    Many greetings
    Nico

    • Sandeep_PowerBI's avatar
      Sandeep_PowerBI
      Frequent Visitor

      Dear Nico,

       

      We cannot do with existing Bar charts, As per my knowledge. we have to use Custom visuals to get as per your design and can add upto 3 values in Y-Axis. Regarding Formating, have good options...

       

       

      If you like my answer, Please mark it as accepted solution! 

       

      Thank you!

      Sandeep

  • Hi Nic 

    As Sandeep_PowerBI  suggested, a custom visual can help solve this. Since you need dual axis, you can use the Dual Y-Axis column custom visual by PBIVizEdit instead of the Lipstick Column custom visual.
    You will need to adjust the offset and bar size for each column as shown in screenshots 2 and 3 in order to get to your desired visual.

    Here is the appsource link for the viz -
    https://appsource.microsoft.com/en-us/product/power-bi-visuals/yavdaanalyticspvtltd1628223732998.dualyaxiscolumnchart?exp=kyyw&tab=Overview


     

     

     

    • Nico_Schulze's avatar
      Nico_Schulze
      Frequent Visitor

      Hey,

       

      thanks a lot for your help! I would like to determine the minimum and maximum value of my y-axes myself. But unfortunately I can't find a function for that. This is done automatically. Do you know how this would work?

       

      Many greetings
      Nico

      • asitm's avatar
        asitm
        Icon for Helper III rankHelper III

        Hi Nico,

         

        I modified the visual using the GUI editor at PBIVizEdit and below is link to the file (both the custom visual .pbiviz and the sample report .pbix) that allows you to fix y-axis range.

        https://drive.google.com/drive/folders/1icUte3Co12Ohpk52g7irkkiUyZ-q0gY9?usp=sharing

        Click on the auto range to toggle on or off. I noticed that at times it may need a double click instead of single click to toggle. not sure why.

        Overall, hopefully this solves your problem.

         

        Regards,
        AsitM