+ Reply to Thread
Results 1 to 8 of 8

Is it possible to calculate averages by grouping weekly columns

  1. #1
    Registered User
    Join Date
    09-21-2020
    Location
    Melbourne, Australia
    MS-Off Ver
    2010
    Posts
    9

    Is it possible to calculate averages by grouping weekly columns

    I have a spreadsheet where a new set of data is entered each week of the year. Future columns are left blank until that weeks data is entered.

    There is an average column already but I would like to add a new column for a running 8 week average which recalculates as each weeks new data is entered. How do I find out the latest 8 weeks in a formula?

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Is it possible to calculate averages by grouping weekly columns

    Please upload a workbook or a representative cut down copy, anonymised if necessary. It is always easier to advise if we can see your request in its context.

    Show a before and after situation with manually calculated results, explaining which information is data and which is results, and if it's not blindingly obvious how you have arrived at your results some explanatory notes as well.

    To upload a file click the Go Advanced button at the foot of your post, look underneath the post area for the Manage Attachments section and take it from there.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Is it possible to calculate averages by grouping weekly columns

    As Richard said, it is always easier when you post a sample workbook to work on.
    However, I recently did something similar and I guess you are looking for something like this.
    Assuming a range like A5:T5, try this for your mobile average of latest eight values:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    It's an array formula, so paste it and confirm with Ctrl+Shift+enter instead of just Enter.

    Good luck!

  4. #4
    Registered User
    Join Date
    09-21-2020
    Location
    Melbourne, Australia
    MS-Off Ver
    2010
    Posts
    9

    Re: Is it possible to calculate averages by grouping weekly columns

    Thanks for that guys, I'm new to this.

    I've uploaded a workbook with sales numbers for each week out of 52. I've given an example of what the formula should achieve based on the current dates in the year. I'm hoping to fund one formula that will calculate this based on the last 8 columns that are not blank which will give me the rolling 8 week average.
    Attached Files Attached Files

  5. #5
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Is it possible to calculate averages by grouping weekly columns

    Try this in C7 and copy down:
    =AVERAGE(OFFSET($D$3,,ROW($Z1)-1,1,8))

  6. #6
    Registered User
    Join Date
    09-21-2020
    Location
    Melbourne, Australia
    MS-Off Ver
    2010
    Posts
    9

    Re: Is it possible to calculate averages by grouping weekly columns

    Seems promising but I don't understand the use of row($Z1)

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

    Re: Is it possible to calculate averages by grouping weekly columns

    If C3 need to do average of last 8 columns those have updated value from the most right

    In C3 then copy down:

    Please Login or Register  to view this content.
    Quang PT

  8. #8
    Registered User
    Join Date
    09-21-2020
    Location
    Melbourne, Australia
    MS-Off Ver
    2010
    Posts
    9

    Re: Is it possible to calculate averages by grouping weekly columns

    That works, thanks very much!

+ 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. Grouping a row of dates and times into weekly averages
    By Nevski79 in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 07-16-2018, 11:23 PM
  2. Please help - calculate weekly averages (many criteria)
    By collegeitdept in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-09-2014, 03:38 PM
  3. Replies: 3
    Last Post: 10-01-2013, 05:05 AM
  4. [SOLVED] Macro to calculate the averages of a varying number of columns
    By jtable in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-12-2013, 10:36 AM
  5. Replies: 3
    Last Post: 03-28-2013, 12:41 PM
  6. Calculate the variances of averages and forecast the future values of 6 columns
    By The Learner in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 10-04-2012, 08:48 AM
  7. Replies: 1
    Last Post: 05-02-2008, 10:41 AM

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