+ Reply to Thread
Results 1 to 7 of 7

30d moving average

  1. #1
    Forum Contributor
    Join Date
    12-09-2022
    Location
    Australia
    MS-Off Ver
    365
    Posts
    103

    30d moving average

    Hi All,

    Please can you help me .
    My spreadsheet is like this (please see the attached):

    1. Column A : Dates (Every day's Date):
    2. Column B : Data numbers (daily value)


    So i want to formular to calculate 30days moving average.

    The formula must look at every in-Column A and calculate 30days moving average from the corresponding data in column B.


    Many thanks
    Attached Files Attached Files

  2. #2
    Forum Contributor
    Join Date
    09-03-2016
    Location
    Catania, Italy
    MS-Off Ver
    Excel 2019
    Posts
    164

    Re: 30d moving average

    HI
    If I understand your intent, put in C31 =AVERAGE(B2:B31) and copy below.
    HI
    Mario

  3. #3
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,987

    Re: 30d moving average

    Or, in row 2 copied down:
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    This give an average for the ranges where there are less than 30 days, assuming that is required.
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  4. #4
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,474

    Re: 30d moving average

    Or if you want a SINGLE value, that is the average of the most recent 30 days:

    =AVERAGE(TAKE(FILTER(B2:B1000,B2:B1000<>""),-30))

    change the 1000 (red) if needed.
    Attached Files Attached Files
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  5. #5
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,987

    Re: 30d moving average

    If you want to ignore the zeroes in the first few cells

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

  6. #6
    Forum Contributor
    Join Date
    12-09-2022
    Location
    Australia
    MS-Off Ver
    365
    Posts
    103

    Re: 30d moving average

    Thanks everyone

  7. #7
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,987

    Re: 30d moving average

    You're welcome. Thanks for the rep.

+ 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. moving average
    By maher2014 in forum Excel General
    Replies: 11
    Last Post: 11-10-2018, 02:31 AM
  2. Replies: 1
    Last Post: 10-20-2014, 03:20 PM
  3. [SOLVED] Moving average
    By burdo77 in forum Excel General
    Replies: 7
    Last Post: 10-01-2014, 10:53 AM
  4. [SOLVED] Moving average/average function/adjustable length
    By Lv27 in forum Excel General
    Replies: 3
    Last Post: 08-16-2012, 09:43 AM
  5. Moving Average
    By murid in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 02-16-2009, 03:13 AM
  6. Charts 5 day moving average, 10 day moving average
    By monalisa in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-28-2008, 09:50 PM
  7. Moving average of a moving average in the same cell
    By philroberts1983 in forum Excel General
    Replies: 8
    Last Post: 09-16-2008, 07:36 AM

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