Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Agnieszka
Frequent Visitor

Maps - color saturation based on customised regions

Hi Guys,

 

 

I would like to create a shape map where colour saturation depends on the value for the customised region.

 

I have downloaded a shape map of the world and connected it to my data via ISO codes (I have ISO in the 'Location' box). I put 'Units Delta' in the Color Saturation and I get a nice map where the countries are colored in shades of red for negative values and in shades of green for positive values.

 

Now I would like to have similar map, but with coloring based on values for not single countries but regions as a whole. E.g. if I had a region containing two countries: country A with units delta of -50, country B with units delta of 140, I would like them both colored in the same shade of green associated with the units delta of 90.

 

I have the regions specified in one of the columns of my data. I have tried putting RegionName in the Legend, but what I achieved was having the countries in different colors depending only on the region, without taking into consideration the units delta at all...

 

Any suggestions how can I proceed here?

2 REPLIES 2
v-sihou-msft
Employee
Employee

@Agnieszka

 

For your requirement, you need to add a REGION column in your dataset. Then create a measure to calculate the 'Units Delta' group on REGION:

 

Region Total Units Delta=CALCULATE(SUM(Table[Units Delta]),ALLEXCEPT(Table,Table[REGION]))

Now you can put above measure into color saturation.

 

 

Regards,

Hi @v-sihou-msft,

 

Thank you for your reply. I have tried exactly that and neverthless didn't get the desired result.

 

GTMU Delta regional = CALCULATE(sum(Query1[GSales Units]),ALLEXCEPT(Query1,Query1[RegionKey]))-CALCULATE(sum(Query1[Previous GSales Units]),ALLEXCEPT(Query1,Query1[RegionKey]))

After I add the measure above to the Color Saturation field, without the Region as Legend it just colors all countries the same, after I add Region to Legend, regions are colored differently, but irrespective of the regional delta value.

 

 

Could you please let me know where do you think is the issue with my approach?

 

Thank you,

Agnieszka

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.