+ Reply to Thread
Results 1 to 4 of 4

AverageIF for group of people in longer list

  1. #1
    Registered User
    Join Date
    05-28-2010
    Location
    Washington, DC
    MS-Off Ver
    Excel 2007
    Posts
    2

    AverageIF for group of people in longer list

    Hello,

    I've been searching forums everywhere, and have tried many things, but can not figure out how to do this.

    I have a long list of employee titles, and scores for each of them. I would like to take the average of only a select group of those employees. There are multiple data points with the same title. For example, if there were fifteen titles, I would like to know the average for just a group of three of those titles.

    =AVERAGE(IF((ALL TITLES=A1:A3)*(ALL TITLES=Title One)*(ALL TITLES=Title One)*(Score>0),Score))
    ...where A1:A3 are the select titles I would like to average for.

    More explicitly, I tried:

    =AVERAGE(IF((ALL TITLES=Title One)*(ALL TITLES=Title Two)*(ALL TITLES=Title Three)*(Score>0),Score))

    ...I know Arrays are usually for saying condition one AND condition two, but I am trying to say Condition one or Condition two (Without the OR function because that relies on true/false.

    I've been able to successfully use this formula for finding the average for a single title, but the challenge has been saying "if any of these titles match any titles in the list, then take the average of just those". I have tried AverageIFS, Sumif/Countif, Vloookup to no avail. I am doing this for 66 different categories, which is why I am trying to consolidate this into one formula.
    Last edited by JohnJohnson; 05-28-2010 at 12:10 PM.

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: AverageIF for group of people in longer list

    Try

    =AVERAGE(IF( ( (ALL TITLES=Title One) + (ALL TITLES=Title Two) + (ALL TITLES=Title Three) ) * (Score>0), Score))

    The first three terms are mutually exclusive, so their sum can be, at most, 1.
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: AverageIF for group of people in longer list

    You could use MATCH, i.e.

    =AVERAGE(IF(ISNUMBER(MATCH(ALL TITLES,A1:A3,0)),IF(Score>0,Score)))

  4. #4
    Registered User
    Join Date
    05-28-2010
    Location
    Washington, DC
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: AverageIF for group of people in longer list

    I can't believe how much time I spent looking for that on forums. Thank you so much.

+ 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