+ Reply to Thread
Results 1 to 7 of 7

Calculating ppts difference from % of column total data in a pivot table

  1. #1
    Registered User
    Join Date
    05-09-2017
    Location
    London
    MS-Off Ver
    Office 2013
    Posts
    3

    Calculating ppts difference from % of column total data in a pivot table

    Hi!

    I have created the following pivot table in excel:



    Pivot Table 1.PNG

    What I'd like to have is a column showing the ppts difference between "sum of PAX_TY" and "sum of PAX_LY". The problem is that the data is displayed in the form of % of column total therefore creating a calculated field doesn't work (as you can see above) as the raw data looks like this:

    Pivot Table 2.PNG

    Any ideas how I might be able to display the difference between "sum of PAX_TY" and "sum of PAX_LY" in the first pivot table?

  2. #2
    Forum Contributor noboffinme's Avatar
    Join Date
    08-29-2013
    Location
    Melbourne, Australia
    MS-Off Ver
    Excel 2003/7/10/13/16/19
    Posts
    1,067

    Re: Calculating ppts difference from % of column total data in a pivot table

    Hi, Can you post an example file?
    Remember you are unique, like everyone else

  3. #3
    Registered User
    Join Date
    05-09-2017
    Location
    London
    MS-Off Ver
    Office 2013
    Posts
    3

    Re: Calculating ppts difference from % of column total data in a pivot table

    Hi!

    I've attached the data below (all publically available). Just to be clear I'm looking to get capacity share data ppts vLY i.e. on the pivot table tab to have the first column minus the second column (when in %of column total form)

    Toby
    Attached Files Attached Files

  4. #4
    Forum Contributor noboffinme's Avatar
    Join Date
    08-29-2013
    Location
    Melbourne, Australia
    MS-Off Ver
    Excel 2003/7/10/13/16/19
    Posts
    1,067

    Re: Calculating ppts difference from % of column total data in a pivot table

    Hi,
    I need you to be clear with your explanations so I can follow what you want. On the 'Pivot Table' worksheet you want to subtract Cell 'D7' from Cell 'C7' & have the results displayed as a %?

    Can you explain what you need in a similar way? I have no idea what 'capacity share data ppts vLY' means.

  5. #5
    Registered User
    Join Date
    05-09-2017
    Location
    London
    MS-Off Ver
    Office 2013
    Posts
    3

    Re: Calculating ppts difference from % of column total data in a pivot table

    Hi sorry,

    So basically the data shows the number of passengers that flew from London to a particular destination this year and last year. What I want to show is the market share for each carrier on each route (e.g. Chicago (CHI)) which is calculated by the total number of passengers that travelled from London to Chicago with a particular carrier divided by the total number of passengers that travelled from London to Chicago with any carrier.

    I have calculated this for both this year and last year which you can see in the pivot table tab using the %of column total functionality. What I wish to show however is the difference in market share between this year and last year.

    For example if American flew 200 passengers this year and 300 last year, and United flew 300 this year and 200 last year (for simplicity assume American and United are the only carriers passengers used to go from London to Chicago). American's share this year would be 40% compared to 60% last year so the vLY column would show -20% as their share was 20% lower than last year. United's share would be 60% this year and 40% last year so their share was 20% higher than last year.

    The problem is that a simple calculative field does not work as it would do 200-300 = -100 (for American) and 300-200 = 100 (for United) but setting it as % of column total clearly won't give me the -20% as desired as the column total is 0.

    Thanks for your help, Toby

    EDIT: Sorry to make it more in excel speak I want to take the difference of the two columns in the pivot table (for each POS) which are in the form of % of column total
    Last edited by TJGriffiths; 05-10-2017 at 05:45 AM.

  6. #6
    Forum Contributor noboffinme's Avatar
    Join Date
    08-29-2013
    Location
    Melbourne, Australia
    MS-Off Ver
    Excel 2003/7/10/13/16/19
    Posts
    1,067

    Re: Calculating ppts difference from % of column total data in a pivot table

    Hi Toby,

    Thanks that's much clearer. I've attached your file with 2 pivots I've created.

    One gives the total Pax for each Origin to Destination combination for all airlines.

    The other is the same but for each airline.

    Going from your info, you want to divide/subtract one from the other to get your market share result.

    Am I understanding you correctly? If so, can you advise how you're getting these figures with your current method?

    Cheers Peter

  7. #7
    Forum Contributor noboffinme's Avatar
    Join Date
    08-29-2013
    Location
    Melbourne, Australia
    MS-Off Ver
    Excel 2003/7/10/13/16/19
    Posts
    1,067

    Re: Calculating ppts difference from % of column total data in a pivot table

    Sorry, forgot to add the file.
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Pivot Table % Difference Running Total
    By spitfireblue in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 01-14-2016, 03:00 AM
  2. Adding a formula column based on the pivot table's Grand Total column
    By trisoldee in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 12-26-2014, 05:29 PM
  3. Pivot Table Total doesn't match data total
    By CNL.Excel in forum Excel Charting & Pivots
    Replies: 4
    Last Post: 10-31-2013, 07:40 PM
  4. Replies: 8
    Last Post: 08-21-2013, 07:57 PM
  5. Pivot table - calculating percentage on grand total
    By sri023 in forum Excel General
    Replies: 3
    Last Post: 07-13-2012, 02:42 PM
  6. [SOLVED] Calculating difference on Pivot Table Totals
    By PSM in forum Excel General
    Replies: 0
    Last Post: 01-12-2006, 11:40 PM
  7. Replies: 7
    Last Post: 01-30-2005, 02:06 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1