+ Reply to Thread
Results 1 to 3 of 3

Median calculation across two columns

  1. #1
    Registered User
    Join Date
    06-21-2011
    Location
    UK
    MS-Off Ver
    Excel 2007
    Posts
    2

    Median calculation across two columns

    Apologies if this is a simple query, I have struggled to find an obvious solution on the wider web, though.

    I am trying to calculate the median sale price across a total number of sales. Total 2046 sales at 17 different prices.

    The data is in two columns. The first column contains the unit price. The second column contains the number of sales of that unit at that price.

    Data in the attachement.

    Any assistance appreciated.
    Attached Files Attached Files
    Last edited by captainjazz; 06-21-2011 at 08:35 AM.

  2. #2
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Median calculation across two columns

    by inspection median is 9 (in c3 put = b3,in c4 put =b4+c3 drag down
    median is the middle number (or mean of the middle 2 numbers if range even)
    your median lies at sum(b3:b19)/2 which is 1023
    you can see it lies between 985 and 1189 which corresponds to £9
    the average price would be
    =SUMPRODUCT(A3:A19,B3:B19)/SUM(B3:B19) which =£8.67
    Last edited by martindwilson; 06-21-2011 at 09:34 AM.
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  3. #3
    Registered User
    Join Date
    06-21-2011
    Location
    UK
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: Median calculation across two columns

    Thanks martindwilson. That makes sense.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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