+ Reply to Thread
Results 1 to 5 of 5

Advanced Aggregate function? - Find average without zeros and without lowest value

  1. #1
    Registered User
    Join Date
    09-02-2020
    Location
    PA
    MS-Off Ver
    Excel 2010
    Posts
    2

    Advanced Aggregate function? - Find average without zeros and without lowest value

    I am trying to find a formula that gets me the average number(Dollars) for the entire column but it needs to ignore the zeros/blank along with the lowest number. I thought this would be an aggregate function - another aggregate function but cannot get it to work. So in the example below I need it to ignore the zeros along with the -$5412. Greatly appreciate any help.

    example column A:
    $630
    $(212)
    $205
    $502
    $(5412)
    $0
    $0
    $0

  2. #2
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,463

    Re: Advanced Aggregate function? - Find average without zeros and without lowest value

    It assums data in A1:A8

    Try:

    Please Login or Register  to view this content.
    Attached Images Attached Images
    Quang PT

  3. #3
    Registered User
    Join Date
    08-13-2020
    Location
    Georgia, United States of America
    MS-Off Ver
    2016
    Posts
    8

    Re: Advanced Aggregate function? - Find average without zeros and without lowest value

    =(sum(a1:a8)-min(a1:a8))/(countif(a1:a8,"<>0")-1)

  4. #4
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,463

    Re: Advanced Aggregate function? - Find average without zeros and without lowest value

    Quote Originally Posted by hbgurley View Post
    =(sum(a1:a8)-min(a1:a8))/(countif(a1:a8,"<>0")-1)
    Assume column A is a list of "zero" and positive numbers
    (sum(a1:a8)-min(a1:a8)) sum all values that greater than 0, including smalles valuest that greater than 0
    i,e

    630
    2
    205
    502
    1
    0
    0
    0

    returns 335, while it should be 334.75

  5. #5
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,933

    Re: Advanced Aggregate function? - Find average without zeros and without lowest value

    How is this fundamentally different from your other thread here?
    https://www.excelforum.com/excel-for...est-value.html

    Seems to me you are asking the same thing, just changing the data
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

+ 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. Replies: 2
    Last Post: 09-03-2020, 12:48 AM
  2. [SOLVED] Find average of lowest 5 values in a column
    By Captnpiggy in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 02-24-2014, 04:45 PM
  3. [SOLVED] how to find average of a range excluding the zeros.
    By sumesh56 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-06-2013, 10:28 PM
  4. Average of the ten lowest numbers in a row of twenty, excluding zeros.
    By gewing in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 02-25-2013, 05:52 AM
  5. [SOLVED] Average for non-consecutive cells excluding zeros (even when they all contain zeros)
    By pao13 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 11-05-2012, 04:32 PM
  6. find average of 5 lowest numbers in 10 excluding zero's
    By GaryL in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-12-2012, 09:33 AM
  7. Find the average of the lowest four values of the last six
    By pjmcc64 in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 05-03-2010, 06:26 PM

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