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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
Anonymous
Not applicable

Heat Map, Correlation Plot, Matrix Table

Hi All, 

 

I am going to give it my best go to articulate what I want to do. I am a relatively new user and despite finding most of power Bi really intuitive I cannot get to the bottom of this. 

 

I have a dataset with profiles of long term conditions (there are 😎 which are all held in fields (with binary 1/0) and the unique identifier is a patient list. Looks a bit like this;

 

                    Diabetes           Heart Failure         Dementia

Patient 1           1                            0                        1

Patient 2           0                            0                        1

Patient 3           1                            1                        1

 

What I want to achieve is somewhere between a correlation plot and a heat map. I want to know for my 8 conditions something along the lines of "how many people have both heart failure and dementia" but for all the possible combinations. (There are many thousands of records). I've achieved this before in Excel but finding it difficult in this context. 

 

An example of what I would like is below. 

 

                             Diabetes           Heart Failure             Dementia

Diabetes                     2                         1                             2

Heart Failure              1                          1                             2

Dementia                   2                          2                             3

 

The correlation plot is the closest I get to this - but I would like a sum of how many people have both or many conditions as opposed to correlation coefficients. 


Thanks v much for any help - all gratefully received, 

 

Emma 

 

 

Correlation coefficient 

3 REPLIES 3
ErikHamoen
Resolver I
Resolver I

I know this topic is quite old, but if anyone still runs into this question: This is how I solved it:
https://sidequests.blog/2023/08/01/creating-a-correlation-matrix-in-power-bi/ 

dax
Community Support
Community Support

Hi EB1991,

If possible, could you please inform me more detailed information(such as your sample data, your logic and your expecting output)? Then I will help you more correctly.

Best Regards,
Zoe Zhi

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

Anonymous
Not applicable

 

 

Hello,

 

I have generated some sample data. This is what I tried to illustrate in the post where it lists patient 1, patient 2 etc. It appears I cannot upload an excel file.

 

Second image below is where I have managed to achieve desired output using Excel. This is my expected output

 

The logic is - that I would like to know is within my population (Circa 20K) how many people have conditions that commonly co-occur. You can see in the second image - there are many people with both frailty and diabetes.


Thanks so much for your help - it is much appreciated,

 

Emma

Picture1.png

 

Albion Street.png

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.