+ Reply to Thread
Results 1 to 8 of 8

AverageIFS not working properly

  1. #1
    Forum Contributor
    Join Date
    02-13-2018
    Location
    USA
    MS-Off Ver
    Office 365
    Posts
    179

    AverageIFS not working properly

    Attached excel file is pretty straight forward with what is happening. The function is breaking at Column (A & B). It is averaging the value "10" in column C, but not A & B, why?

    aveg ifs 2.PNG
    Attached Files Attached Files

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,794

    Re: AverageIFS not working properly

    There is no formula in the attachment - you seem to have copied just values. Please try again.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,196

    Re: AverageIFS not working properly

    It will average if C=10 AND B=9: I suspect this not what you want.

  4. #4
    Forum Contributor
    Join Date
    02-13-2018
    Location
    USA
    MS-Off Ver
    Office 365
    Posts
    179

    Re: AverageIFS not working properly

    I apologize, her eis the formula and I have updated the excel file with the formula also in cell (U15)

    Please Login or Register  to view this content.
    Attached Files Attached Files

  5. #5
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP and 2007
    Posts
    15,827

    Re: AverageIFS not working properly

    I still don't see that formula anywhere in the file (U15 or other).

    What kind of if logic do you expect? Recognize that, as JohnTopley tried to explain, Excel combines the ifs of average ifs in an and logic -- so that all of the conditions must be true for a given record before Excel will include that entry in the average. I note that none of the records in your sample file have 8 in A and 9 in B and 10 in C. I am guessing that Excel is returning Div/0 for the AVERAGEIFS() because there are no records that meet all criteria.

    Perhaps you intended an or logic (average if A is 8 or B is 9 or C is 10)? Or perhaps you intended some other logic? Whatever you intended, it appears that you need to think through the desired logic, then work out a formula or combination of formulas that will correctly represent that logic. It's not clear to me what your desired logic is, so I cannot yet suggest anything.
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  6. #6
    Forum Contributor
    Join Date
    02-13-2018
    Location
    USA
    MS-Off Ver
    Office 365
    Posts
    179

    Re: AverageIFS not working properly

    I reattached with formula this time. I apologize for that. However the screenshot shows that the conditions are being met for Column (A,B,C)
    A= 8
    B=9
    C=10

    I need the averageifs to run based off the criteria in this example. If you test the formula in FX, you can see it working on column C with the condition of "10", then when I try and include column B, condition of "9", it breaks.
    Attached Files Attached Files

  7. #7
    Forum Expert
    Join Date
    05-01-2014
    Location
    California, US
    MS-Off Ver
    Excel 2010
    Posts
    1,795

    Re: AverageIFS not working properly

    @Shruder.... U15 displays a #DIV/0 error. The formula is:

    =AVERAGEIFS(L:L,D:D,D2,E:E,E2,F:F,F2,G:G,G2,I:I,I2,T:T,T2,U:U,U2,V:V,V2,C:C,10,B:B,9,A:A,8)

    The formula =COUNTIFS(D:D,D2,E:E,E2,F:F,F2,G:G,G2,I:I,I2,T:T,T2,U:U,U2,V:V,V2,C:C,10,B:B,9,A:A,8) returns zero. So there is indeed no row that satisfies all conditions (at the same time).

    So AVERAGEIFS is correct to return a #DIV/0 error.

    A visual inspection confirms that. At the very least, you require a row where A is 8 and B is 9 and C is 10. I do not see any such row.

  8. #8
    Forum Contributor
    Join Date
    02-13-2018
    Location
    USA
    MS-Off Ver
    Office 365
    Posts
    179

    Re: AverageIFS not working properly

    That is interesting, I will keep trying other formulas then.

    thanks for looking at this

+ 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. AVERAGEIFS not working
    By emielbrak in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 10-18-2015, 10:27 AM
  2. averageifs() using date range - not working
    By lampropeltis in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 07-31-2015, 02:09 PM
  3. Averageifs formula no longer working
    By Marieme in forum Excel Formulas & Functions
    Replies: 30
    Last Post: 12-18-2014, 11:00 AM
  4. VBA not working properly
    By stevemills04 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-26-2013, 02:56 PM
  5. [SOLVED] trying to take averageifs and ignore the blank cells, not working
    By cgabe001 in forum Excel General
    Replies: 2
    Last Post: 12-27-2012, 10:19 AM
  6. Excel 2007 : AVERAGEIFS formula not working
    By milliemoo in forum Excel General
    Replies: 5
    Last Post: 03-07-2012, 09:19 AM
  7. UDF not working properly
    By demuro1 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-09-2008, 04:36 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