LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #12   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 41
Default Create a 12 month rolling average

Hi again

When I verified this formula, I had a problem.

The earliest data is in column B and the latest is in V. The next column to
be filled is in W. This formula doesn't work well if Column W is left blank.

I've attached a sample from my file.

Months Category 1 Category 2 Category 3
Apr 06 438 2429 187
May 06 468 2509 188
Jun 06 386 2356 115
Jul 06 439.99 2494.934
Aug 06 418.738 2623.68
Sep 06 476.762 2818.631
Oct 06 384.501 2800.796
Nov 06 500.444 2805.878 1286.587
Dec 06 411.816 2857.546 1048.737
Jan 07 595.142 3119.351 1357.796
Feb 07 440.891 3119.204 1611.12
Mar 07 548.954 3349.091 1877.482
Apr 07 501.714 3103.273 1369.555
May 07 526.133 2728.437
Jun 07 536.357 2538.707
Jul 07 485.514
Aug 07 457.713
Sep 07 404.142
Oct 07 459.103
Nov 07 418.293
Dec 07 350.3


"12 month
rolling" 477.0213333 2863.294 1106.772375
Check 477.0213333 2993.0105 1553.98825

J

"Max" wrote:

Can I use this** formula if I only want to create a rolling average based
on
the 12 most recent months (even if it includes blanks)?


**That's exactly what the formula I gave does when you enter the col labels
in row2 progressively each month from left to right within the range B2:U2.

**Put in AB3, array-enter the formula, copied down:
=AVERAGE(OFFSET(B3,,MAX(($B$2:$U$2<"")*(COLUMN($B $2:$U$2)))-2,,-12))

The "MAX(...)-2" part of it in the OFFSET anchors/fixes the rightmost
startpoint, ie the most "recent" col (col param) while the -12 (width param)
then grabs the 12 cols range to the left of this anchor col. The minus
in -12 means to the left.

If you carefully select just the OFFSET(...) part of it within the formula
bar and then press F9 to evaluate, the 12 "recent" cols range will be
revealed. Use this as a visual check.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---



 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to create a rolling 6 month average? anley Excel Discussion (Misc queries) 3 August 14th 06 12:41 PM
rolling 12 month average gevans Excel Worksheet Functions 5 February 21st 06 01:09 PM
Formula for calculating a rolling 12 month average in excel? Jeff Excel Discussion (Misc queries) 1 December 9th 05 09:11 PM
How do I create a rolling average chart, adding most recent data? Doug@NxEdge Charts and Charting in Excel 1 November 5th 05 02:22 AM
How can I create a rolling average between 2 values? tomcat Excel Worksheet Functions 2 January 28th 05 02:49 PM


All times are GMT +1. The time now is 06:36 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"