View Single Post
  #3   Report Post  
Max
 
Posts: n/a
Default Average Function with Day of Week Criteria

... and a quick sample, in case needed:
http://cjoint.com/?lck01cr7y4
Cheese_newusers.xls

Note that the average formula as suggested will ignore empty cells or
formula cells within B1:B200 evaluating to null (""), re - the condition:
.... ($B$1:$B$200<"") ..

If we need it to ignore cells containing zeros as well,
then we could add-on say, the condition: .. ($B$1:$B$2000) ..
i.e. put instead in D1, array-enter as before, and copy down to D7:

=AVERAGE(IF(($B$1:$B$2000)*($B$1:$B$200<"")*($A$ 1:$A$200=C1),$B$1:$B$200))

--
Rgds
Max
xl 97
---
Singapore, GMT+8
xdemechanik
http://savefile.com/projects/236895
--