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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Anonymous
Not applicable

How to calculate variance ?

Hello, 
I have table that looks like this:

slav84_0-1627483296794.png

 

I created matrix like this:

slav84_1-1627483675496.png

 

What i really need is matrics that has Variances which is 2021-2020 and also %YoY which would be Variance/2020.
So something like this:

FiscalWeek20202021Variance%YoY
Week-11191331412%
Week-213313300%
Week-31121261413%
Week-4133119-14-11%
Week-511211200%
Week-613314075%
Week-7126112-14-11%
Week-811912676%
Week-912612600%
Week-10133119-14-11%
Week-111261401411%
Week-121121261413%
Week-131191331412%
Week-14119105-14-12%
Week-151051332827%
Week-16119112-7-6%
Week-1711211200%

 

And ultimatelly i need to be able to grab data from 2020, 2021 and %YoY and plot it on the line chart. 
Can this be done?

1 REPLY 1
v-angzheng-msft
Community Support
Community Support

Hi, @Anonymous 

 

If you keep your data structure, then you can't get the above matrix effect, unless you pivot the year column, and then use a table to achieve such a visual effect.

Matrix:

vangzhengmsft_0-1627640417752.png

Pivot the year column and use a table visual.

vangzhengmsft_1-1627640470547.pngvangzhengmsft_2-1627640529289.png

Please refer to the attachment below for details

 

 

Hope this helps.

 

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

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.

Top Solution Authors