Forum Discussion

andyspa's avatar
andyspa
Helper I
5 years ago
Solved

Market share in Map Visualization

Hello everybody,

 

I have the following data.

 

I want to create a Map in Power BI to show on a first level the country, then the town. Legend must show the players and the balls size the indistinct count of sites. All clear until now. However, I wanted to add in the tooltip  the info of the Market share. When I have the "town level" it's correct, when I zoom out at country level it returns completely wrong values. Is there something I can do to make it aggregate those? Perhaps some calculation in the excel source file?

 

Thanks in advance for your help.

 

Regards,

Andrea

 

  • Hi, andyspa 

     

    You may try the following measure to see if it helps. 

    Measure = 
    DIVIDE(
        SUM('Table'[Market Share]),
        CALCULATE(
            SUM('Table'[Market Share]),
            ALLEXCEPT('Table','Table'[Country])
        )
    )

     

    Result:

     

    Best Regards

    Allan

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

8 Replies

  • andyspa 

    Please share your data in file format.

    An image of what you currently have and what isn't right would also help.

    Regards

    Phil

    • andyspa's avatar
      andyspa
      Helper I

      Hello PhilipTreacy,

       

      do you know ho can I share the file? I don't have the option here.

       

      Cheers,

      Andrea

  • HI andyspa 

    Upload the file to OneDrive, Dropbox or similar then share the link to the file here.

    Regards

    Phil

    • andyspa's avatar
      andyspa
      Helper I

      Thanks Phil, I did already in the original post. Anyhow here you can find it 🙂


      Thanks

  • v-alq-msft's avatar
    v-alq-msft
    Community Support

    Hi, andyspa 

     

    It seems correct from the visual. Could you please show us the expected result for better understand?

     

    Best Regards

    Allan

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • andyspa's avatar
      andyspa
      Helper I

      Hello v-alq-msft ,

       

      I want to show the real market share when moving the cursor to the pie slice, not 1830%! Cannot be more than 100%.

       

      Thanks.

      Andrea

      • v-alq-msft's avatar
        v-alq-msft
        Community Support

        Hi, andyspa 

         

        You may try the following measure to see if it helps. 

        Measure = 
        DIVIDE(
            SUM('Table'[Market Share]),
            CALCULATE(
                SUM('Table'[Market Share]),
                ALLEXCEPT('Table','Table'[Country])
            )
        )

         

        Result:

         

        Best Regards

        Allan

         

        If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

  • ian_abq's avatar
    ian_abq
    Regular Visitor

    Could you to make the file available again?

    I'm having trouble making the pie graph inside the maps visualization.