Hi Tim
you can use Herbert's elegant solution in earlier versions of Excel.
With the source data set up as he has shown, (but not as a table), then the
formulae would become
D5
=DATE(YEAR(Sheet1!$B$5:$B$119),MONTH(Sheet1!$B$5:$B$119),1)
E5
=COUNTIFS(Sheet1!$D$5:$D$119,Sheet1!$D$5:$D$119)
F5
=SUMPRODUCT((Sheet1!$C$5:$C$119)*
(Sheet1!$D$5:$D$119=EDATE(Sheet1!$D5,{0,-1,-2,-3,-4,-5,-6,-7,-8,-9,-10,-11})))
/Sheet1!$E$5:$E$119
Clearly these formulae are using fixed ranges, the size of Herbert's source
data.
You would be better creating Dynamic Named ranges
Insert>name>Define
Name lrow
Refers to =COUNTA(Sheet1!$B:$B)
Name DDate
Refers to =Sheet1!$B$5:INDEX(Sheet1!$B:$B,lrow)
Name Amt
Refers to =Sheet1!$C$5:INDEX(Sheet1!$C:$C,lrow)
Repeat for the other column names, and substitute the names in place of the
fixed ranges in the formulae.
(I have written some code for generating dynamic named ranges for each used
column in a workbook, which can be downloaded from
http://www.contextures.com/xlNames03.html)
Be aware, that you also need to use Tools>Addins>Analysis Toolpak, in order
to have the EDATE function available to you.