Forum Discussion

Junaid11's avatar
Junaid11
Icon for Helper V rankHelper V
3 years ago
Solved

Variance based on Category and Period

Hello,
I have a table which look like below:

PeriodCategorySales
1Apple9235
1Orange3461
1Banana376
2Apple1257
2Orange3562
2Banana8093
3Apple961
3Orange468
3Banana236

 

I want to do the variance among categories based on Period. For example in slicer of period if I choose Period 1 and Period 2 the variance should be shown against the category as shown in the picture below:

Apple7978
Orange-101
Banana-7717
  

Similarly If I choose the slicer 1 and 3 the ourcome would be the variance between both the periods as below:

Apple8274
Orange2993
Banana140

I just want the variance to filter automatically between the two selection made in the slicer. 
Your help would be highly appreciated.
Thank you