+ Reply to Thread
Results 1 to 7 of 7

Sum last 5 or less in a column

  1. #1
    Registered User
    Join Date
    10-27-2012
    Location
    home, IL
    MS-Off Ver
    Excel 2003
    Posts
    3

    Sum last 5 or less in a column

    Hello all, New here. Please be gentle, I tried the search function. What I need to do is average the last 6 or less values in a column b3:b13. I can't seem to figure it out "or less" please help!!

  2. #2
    Forum Expert Moo the Dog's Avatar
    Join Date
    09-28-2012
    Location
    Wisconsin
    MS-Off Ver
    Office 365 (PC & Mac)
    Posts
    1,845

    Re: Sum last 5 or less in a column

    What determines how many values are averaged?

    - Moo

  3. #3
    Registered User
    Join Date
    10-27-2012
    Location
    home, IL
    MS-Off Ver
    Excel 2003
    Posts
    3

    Re: Sum last 5 or less in a column

    Quote Originally Posted by Moo the Dog View Post
    What determines how many values are averaged?

    - Moo
    It is a monthly input, but I only need the last 6 values or less averaged. So if 2 or more cells have a value average or if more than 6 have a value, then only the last 6. Thanks!

  4. #4
    Forum Expert Moo the Dog's Avatar
    Join Date
    09-28-2012
    Location
    Wisconsin
    MS-Off Ver
    Office 365 (PC & Mac)
    Posts
    1,845

    Re: Sum last 5 or less in a column

    Try this in Excel 2003:
    You must hit Ctrl+Shift+Enter instead of just Enter when you type in this formula (it's an array formula)
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    ..or in Excel 2007:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    * That will average the values in B8:B13. (Assuming the last 6 values would be in those cells) If the values appear anywhere in the range of B3:B13 then those formulas won't work.
    -Moo
    Last edited by Moo the Dog; 10-27-2012 at 10:36 AM. Reason: added note

  5. #5
    Banned User!
    Join Date
    10-14-2006
    Posts
    1,211

    Re: Sum last 5 or less in a column

    Average the last 6 values

    =AVERAGE(INDEX(A2:A1000,MATCH(10^10,A2:A1000)):INDEX(A2:A1000,MATCH(10^10,A2:A1000)-MIN(5,COUNT(A2:A1000))))

    Adjust your range to suit
    Last edited by Teethless mama; 10-27-2012 at 10:43 AM.

  6. #6
    Registered User
    Join Date
    10-27-2012
    Location
    home, IL
    MS-Off Ver
    Excel 2003
    Posts
    3

    Re: Sum last 5 or less in a column

    Teethless, Thank you!! Do I click something that increases your Rep? Not sure of the proper etiquette.

  7. #7
    Forum Expert Moo the Dog's Avatar
    Join Date
    09-28-2012
    Location
    Wisconsin
    MS-Off Ver
    Office 365 (PC & Mac)
    Posts
    1,845

    Re: Sum last 5 or less in a column

    Quote Originally Posted by Teethless mama View Post
    Average the last 6 values

    =AVERAGE(INDEX(A2:A1000,MATCH(10^10,A2:A1000)):INDEX(A2:A1000,MATCH(10^10,A2:A1000)-MIN(5,COUNT(A2:A1000))))

    Adjust your range to suit
    Teethless mama,

    For some reason I tried that formula and I am getting the wrong result. See attached sheet. Did I input something incorrectly? I changed the formula to match the OP's range (B3:B13):
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    - Moo
    Attached Files Attached Files

+ 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