View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
T. Valko T. Valko is offline
external usenet poster
 
Posts: 15,768
Default Rolling Averages

This will average the last 4 numbers in column B assuming the data is
entered as a contiguous block. Numbers start in cell B2.

=IF(COUNT(B:B)<4,"",AVERAGE(OFFSET(B2,COUNT(B:B)-1,,-4)))

If there aren't at least 4 numbers to average the formula returns a blank
cell.

--
Biff
Microsoft Excel MVP


"Charliechoo" wrote in message
...
I have an excel spread sheet in column A I have week commencing dates for a
whole year and column B contains the sales data for each of these weeks. I
need excel to give me a continual rolling average for the latest 4 weeks
entered, so that when I enter another week the first week "drops" out and
a
new average is calculated.
I am being told that this enters into the realms of programming and nearly
impossible to do! Can anyone help?

Charlotte
X