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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Anonymous
Not applicable

Power Bi matrix table measure, how to find YoY

I'd like help creating a measure that can find the Year on year (YoY) for the 5 values in my matrix table: Count of weeks, sum of recipients, sum of engaged, engagement rate, and sum of revenue.

The data is dynamic so will be added to each week, this means the YoY measure needs to also be dynamic.

 

This is a copy of my data: https://drive.google.com/file/d/13jZ_9t-XjqM_wdPectPAFbgJpX6Q3g0H/view?usp=sharing

 

To find YoY, I know I need to write a measure that calculates ((latest week/ year before latest week) - 1). I have written a calculated column, Position that finds the latest week = 1, year before latest week = 2, and else = 0.

 

How do I write a measure that I can use in my table to find the YoY for all my values? Any help would be appreciated

 

1 ACCEPTED SOLUTION
v-jingzhang
Community Support
Community Support

Hi @Anonymous 

 

You may use these measures:

 

YOY Recipients = DIVIDE(CALCULATE(SUM(TestData[Recipients]),TestData[Position]=1),CALCULATE(SUM(TestData[Recipients]),TestData[Position]=2))-1
 
YOY Engaged = DIVIDE(CALCULATE(SUM(TestData[Engaged]),TestData[Position]=1),CALCULATE(SUM(TestData[Engaged]),TestData[Position]=2))-1
 
YOY Engagment rate = DIVIDE(CALCULATE([Engagment rate],TestData[Position]=1),CALCULATE([Engagment rate],TestData[Position]=2))-1
 
YOY Revenue = DIVIDE(CALCULATE(SUM(TestData[Revenue]),TestData[Position]=1),CALCULATE(SUM(TestData[Revenue]),TestData[Position]=2))-1 

vjingzhang_1-1678686365414.png

 

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

View solution in original post

2 REPLIES 2
v-jingzhang
Community Support
Community Support

Hi @Anonymous 

 

You may use these measures:

 

YOY Recipients = DIVIDE(CALCULATE(SUM(TestData[Recipients]),TestData[Position]=1),CALCULATE(SUM(TestData[Recipients]),TestData[Position]=2))-1
 
YOY Engaged = DIVIDE(CALCULATE(SUM(TestData[Engaged]),TestData[Position]=1),CALCULATE(SUM(TestData[Engaged]),TestData[Position]=2))-1
 
YOY Engagment rate = DIVIDE(CALCULATE([Engagment rate],TestData[Position]=1),CALCULATE([Engagment rate],TestData[Position]=2))-1
 
YOY Revenue = DIVIDE(CALCULATE(SUM(TestData[Revenue]),TestData[Position]=1),CALCULATE(SUM(TestData[Revenue]),TestData[Position]=2))-1 

vjingzhang_1-1678686365414.png

 

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

Anonymous
Not applicable

Thank you so much, I wouldn't have thought of doing it that way. Have a great day!

 

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 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.