+ Reply to Thread
Results 1 to 5 of 5

Help writing a formula to omit empty cells

  1. #1
    Registered User
    Join Date
    09-15-2010
    Location
    Orlando, FL
    MS-Off Ver
    Excel 2007
    Posts
    25

    Post Help writing a formula to omit empty cells

    I would like to show the average of the contents of rows and columns in a worksheet. The typical formula to do this includes the whole array of cells which skews my average down.

    How do I sum and average the row while not including the blank cells. or
    How do write a formula to omit the unpoopulated cells in an array?

    See attachment for sample

    Thanks
    Attached Files Attached Files
    Last edited by mknispel; 02-16-2011 at 05:59 PM. Reason: I attached a sample of my sheet that I need help with

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Help writing a formula to omit empty cells

    In B8, try:

    =IFERROR(AVERAGEIF(B2:B7,"<>"),"")

    copied across

    In U2, try:

    =IFERROR(AVERAGEIF(B2:T2,"<>"),0)

    copied down.
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Registered User
    Join Date
    09-15-2010
    Location
    Orlando, FL
    MS-Off Ver
    Excel 2007
    Posts
    25

    Re: Help writing a formula to omit empty cells

    Thanks, that was just what I needed. I do not understand the reason for the apostophy quotations in the first formula and apostrophy 0 in the second?


    Quote Originally Posted by NBVC View Post
    In B8, try:

    =IFERROR(AVERAGEIF(B2:B7,"<>"),"")

    copied across

    In U2, try:

    =IFERROR(AVERAGEIF(B2:T2,"<>"),0)

    copied down.

  4. #4
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Help writing a formula to omit empty cells

    ooops.. both should have been the same... you can choose either the "" or the 0... this is what is returned instead of an error, when there are no numbers to average... the "" means blank, the 0, well, means 0.

  5. #5
    Registered User
    Join Date
    09-15-2010
    Location
    Orlando, FL
    MS-Off Ver
    Excel 2007
    Posts
    25

    Re: Help writing a formula to omit empty cells

    Once again, much thanks.

+ 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