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

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
stochasticKL
Frequent Visitor

Need Opinion - Optimize Matrix Visualization with Multiple Measures

Hi,

 

I'm trying to create a matrix visual for different company KRAs. I have five different result areas (RA) in different tables. Each RA table looks like this:

Result AreaHierarchy 1Hierarch 2DateValue
RA_1H1_AH2_A1/1/20201
RA_1H1_AH2_B1/1/20201
RA_1H1_AH2_A12/1/20192

 

My goal is to visualize it to a single matrix with Result Area, Hierarchy 1, Hierarchy 2 as rows and Current Month, Previous Month, Previous Year, and Corresponding %Change as columns. Note that each RA is computed differently (e.g. RA_1 is aggregated as a SUM, RA_2 as an AVERAGE, RA_3 as LAST VALUE). Moreover, I have to use measures for the columns so that it dynamically computes values depending on the selected month and year. What I've done so far: 

 

  1. In power query, I appended these RA tables into a single Main table (around 5,000 rows by 5 columns).
  2. To create a measure for the Current Month, I have to create a measure which switches between formulas depending on which RA row it is SWITCH ( MAX ( Result Area ) , "RA_1" , *SUM* , "RA_2" , *AVERAGE* )  .
  3. Previous months where then calculated from the Current Month using parallel period. 

At first, this seems to run smoothly. But later on, when I add more and more previous months column (say 12 columns for the past 12 months), it takes around 20 secs for the whole matrix to load and its taking up all 8 GB memory.

How can I tackle this situation more efficiently? 

Thank you! 

 

1 REPLY 1
v-juanli-msft
Community Support
Community Support

Hi @stochasticKL 

First, please use View->Performance Analyzer, find what steps cause low performance.

Share the query here, we could discuss how to modify the query to get a more quick performance.

 

When showing last n months data on the matrix, could you accept showing as below:

Capture5.JPG

Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

February Power BI Update Carousel

Power BI Monthly Update - February 2026

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.