Differences between pivottable fields

mhenk

Well-known Member
Joined
Jun 13, 2005
Messages
591
I'm using a pivottable that calculates averages for two fields. Is there a way to add a field to the pivottable that calculates the difference in averages for the two fields?

I want:
Code:
Record Number------Avg of Field1----Avg of Field2----Difference
1234567890123----------(A)-----------------(B)-------[(A)-(B)]
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
Any reason you can't use getpivotdata and place the formula to the right of the table, something like:

=GETPIVOTDATA("Average of Field1",$A$3,"Record#",1234567890123)-GETPIVOTDATA("Average of Field2",$A$3,"Record#",1234567890123)
 
Upvote 0
I want to be able to change the category. In my actual file, there's about 5 different categories in addition to record number, and I want to be able to put in/take out these categories and still have the field work.

But, i did a little algebra and added a formula that does what I want it to do, so thanks!
 
Upvote 0

Forum statistics

Threads
1,214,824
Messages
6,121,783
Members
449,049
Latest member
greyangel23

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