Pivot '% of' from another column's subtotal

mst3kr

New Member
Joined
Apr 15, 2013
Messages
46
Office Version
  1. 2019
  2. 2010
  3. 2007
Platform
  1. Windows
Hello all. Have a PT question I can't find a solution for. I may be overthinking it or going about it the wrong way but...

I have a data set that has item information broken into different segments. In this example, X, Y, Z. I'm using a PT to give me simple subtotals, % increases to last year, & actual difference to LY. What I also need is to calculate what % of that item's actual increase or decrease was to that segment's subtotal of LY.

For example, Item X1 sold 2 more units this year than last year. I need to understand what % the 2 unit difference made up of the overall -3.43% increase. To do that, you take the diff and divide it into the total LY sales for that segment; in this case, all of just the X's. Problem is, I can't get a formula to take the Diff column values for each X Item and divide it by the LY subtotal. I can get the '% of' option to work for either the total parent or grand total but I cannot figure out how to have each segment's diff divide into that segment's LY subtotal.

Can I accomplish this via a PT?

ItemTYLYIncreaseDiff% of LY Subtotal
X150484.17%20.86%
X2756025.00%156.44%
X3100125-20.00%-25-10.73%
X Subtot225233-3.43%-8-3.43%
Y1654835.42%176.59%
Y220017514.29%259.69%
Y3503542.86%155.81%
Y Subtot31525822.09%5722.09%
Z150484.17%21.69%
Z2151050.00%54.24%
Z33060-50.00%-30-25.42%
Z Subtot95118-19.49%-23-19.49%

<colgroup><col><col span="4"><col></colgroup><tbody>
</tbody>
 

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.

Forum statistics

Threads
1,215,343
Messages
6,124,402
Members
449,156
Latest member
LSchleppi

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top