+ Reply to Thread
Results 1 to 6 of 6

suppress #DIV/0 AND averageif [range]>0 Excel 2003

Hybrid View

  1. #1
    Registered User
    Join Date
    05-01-2013
    Location
    Texas, USA
    MS-Off Ver
    Excel 2007
    Posts
    3

    suppress #DIV/0 AND averageif [range]>0 Excel 2003

    Excel2003: I need a weekly average for a range of cells that are formatted for %, while suppressing #DIV/0, AND averaging only cells that are non-zero % (have a number entered in the appropriate DailyPoints worksheet cell). All formulas are arrayed (Ctrl-Shft-Enter).

    WklyAvg formula is {=AVERAGE(IF(B5:F5>0,B5:F5))}

    1) Formula is for a weekly average of daily percentages. Daily (B5:F5): M-67% T-0% W-0% R-0% F-0%, where B5:F5 return points earned/max. points possible (source is points entered for each day on another worksheet, DailyPoints).
    2) Formulas in B5:F5 --for example, B5 formula is =(DailyPoints!C5/StudentInfo!$K$5)
    3) I can eliminate either the #Div/0, or non-zero cells, but not both.

    To summarize the flow of data:
    DailyPoints cell does not have a formula, only a number. EX: 47
    Formulas in B5:F5 EX: {=(DailyPoints!C5/StudentInfo!$K$5)}
    Weekly Avg. Formula: {=AVERAGE(IF(B5:F5>0,B5:F5))}

    Suggestions?

  2. #2
    Forum Contributor
    Join Date
    02-28-2013
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    272

    Re: suppress #DIV/0 AND averageif [range]>0 Excel 2003

    Use this one:
    =SUMIF(B5:B11,">0",B5:B11)/COUNTIF(B5:B11,">0")
    Please consider adding a * if I helped

  3. #3
    Registered User
    Join Date
    05-01-2013
    Location
    Texas, USA
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: suppress #DIV/0 AND averageif [range]>0 Excel 2003

    Quote Originally Posted by wfm007 View Post
    Use this one:
    =SUMIF(B5:B11,">0",B5:B11)/COUNTIF(B5:B11,">0")
    I've already tried the sumif/countif. The formula works, if there's data, but I get the #DIV/0 if the range is empty. I want both: the sumif/countif AND supression of #DIV/0. Maybe Excel 2003 can't do that. It's easy in Excel 2007!

    And how do I upload a spreadsheet portion, for viewing?
    Last edited by TManche; 06-19-2013 at 02:10 PM. Reason: additional request

  4. #4
    Valued Forum Contributor
    Join Date
    10-10-2012
    Location
    New York
    MS-Off Ver
    Excel 2007/2010
    Posts
    337

    Re: suppress #DIV/0 AND averageif [range]>0 Excel 2003

    In order to help you better, please upload a sample spreadsheet with any sensitive information removed.
    Don't just use the answers provided for you. Try to understand how it works by reverse engineering or asking about it.

    Please mark the thread as [SOLVED] (Thread Tools->Mark thread as Solved) when answered.
    If you're happy with an answer given, please click the * under the person's name to boost their reputation.

  5. #5
    Forum Expert Ace_XL's Avatar
    Join Date
    06-04-2012
    Location
    UAE
    MS-Off Ver
    2016
    Posts
    6,074

    Re: suppress #DIV/0 AND averageif [range]>0 Excel 2003

    Enclose in IF(ISERROR(

    hence,
    =IF(ISERROR(AVERAGE(IF(B5:F5>0,B5:F5))),"",AVERAGE(IF(B5:F5>0,B5:F5)))
    array entered

    or

    =IF(ISERROR(SUMIF(B5:B11,">0",B5:B11)/COUNTIF(B5:B11,">0")),"",SUMIF(B5:B11,">0",B5:B11)/COUNTIF(B5:B11,">0"))
    Life's a spreadsheet, Excel!
    Say thanks, Click *

  6. #6
    Valued Forum Contributor
    Join Date
    10-10-2012
    Location
    New York
    MS-Off Ver
    Excel 2007/2010
    Posts
    337

    Re: suppress #DIV/0 AND averageif [range]>0 Excel 2003

    To upload, click go advanced, and manage attachments.

    I think Ace has you covered though.

+ 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