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

The ultimate Microsoft Fabric, Power BI, Azure AI & SQL learning event! Join us in Las Vegas from March 26-28, 2024. Use code MSCUST for a $100 discount. Register Now

Reply
holydragon
Frequent Visitor

OKViz Synoptic Panel - Changing Map colors based on category

Hello,

 

I have created a .svg map for Synoptic Panel that needs to have its areas change based on three different columns of data.  The columns contain the ratings of  high, low, med and the corresponding population, income, and pet ownership.

 

Area   Pop   Income  PO

A1        L          H         L

A2        H         L          M

A3        M        M         H

 

In order to change colors according the category, I reformatted to data to:

Area   Pop   Income  PO

A1        L      Pop

A2        H     Pop

A3        M    Pop

A1        H     Income

A2        L      Income

A3        M    Income

A1        L      PO

A2        M    PO

A3        H     PO

 

When I select Pop - I get the colors corresponding to H, M, L

When I select Income or PO, I get nothing and the values show "blank" when I mouseover the areas.

 

Anyone know how to get this working?

 

What am essentailly doing is using one map for several categories of data.  The color change based on the category selected.

 

 

HD

1 REPLY 1
v-jingzhang
Community Support
Community Support

Hi @holydragon 

 

It's not clear enough. Which data is the "category" data? Does it refer to the population, income, and pet ownership? And are you setting up conditional formatting to change the colors? 

 

Based on my understanding, you can first unpivot the table in Power Query Editor. For the first table, right click on "Area" column header and select "Unpivot Other Columns". 

vjingzhang_1-1651027258223.png

Then create a measure to decide the colors according to rating values. Then use this measure to set the conditional formatting colors. Below is an example with a table visual. 

Color = SWITCH(SELECTEDVALUE('Table'[Value]),"H","Red","M","Yellow","L","Green")

vjingzhang_2-1651027647673.png

 

If this is not what you want, can you provide more details like how do you change colors currently and what is your expected result?

 

Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.

Helpful resources

Announcements
Fabric Community Conference

Microsoft Fabric Community Conference

Join us at our first-ever Microsoft Fabric Community Conference, March 26-28, 2024 in Las Vegas with 100+ sessions by community experts and Microsoft engineering.

February 2024 Update Carousel

Power BI Monthly Update - February 2024

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

Fabric Career Hub

Microsoft Fabric Career Hub

Explore career paths and learn resources in Fabric.

Fabric Partner Community

Microsoft Fabric Partner Community

Engage with the Fabric engineering team, hear of product updates, business opportunities, and resources in the Fabric Partner Community.