+ Reply to Thread
Results 1 to 2 of 2

Lookup return multiple values?

  1. #1
    Registered User
    Join Date
    05-17-2004
    Posts
    9

    Lookup return multiple values?

    Good morning!

    I have a table like the one below that shows a document number and the hours it took to write the document. I'm trying to calculate the averages, medians, percentiles of this table by doc number. I'm guessing something like =AVERAGE(VLOOKUP($A35,$b$1:$b$15,2)) but I can't get the vlookup to return multiple values. Any ideas? Thanks!


    Doc Number Hours
    58 1.0
    340 1.0
    550 2.0
    550 4.0
    555 6.0
    650 14.0
    650 9.0
    650 2.0
    760 9.0
    760 18.0
    760 2.0
    800 2.0
    800 1.0
    800 1.0
    910 1.0

  2. #2
    Forum Contributor
    Join Date
    02-28-2006
    Posts
    690
    use sumproduct to both count how many times the document number occurs and the total number of hours spent writing.

    You will need a spare helper column populated with ones.

    col A......colB.......colC
    22...........3.............1
    33...........4.5...........1
    33...........7.5...........1

    =sumproduct((a1:a3=33)*(c1:c3)) counts how many doc number 33
    =sumproduct((a1:a3=33)*(b1:b3)) adds up the hours spent

    you can now apply or build in your stats formulas

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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