Average of multilpe Sumproduct formulas

jmersing

Well-known Member
Joined
Apr 14, 2004
Messages
887
I'm using the following formulas to get an average of three different ranges. The problem is if one of the ranges has a zero it waters down the average of the whole formula. For example

If the results for each formula are: 10 - 10 - 0 I would want to return the avergae of 10 not 6.6.

Formula
=AVERAGE((SUMPRODUCT(--(SiteRange=Q$9),--(WeekRange=TrendWk1),--(AreaRange=$B154),Trend!$N$2:$N$1250)),(SUMPRODUCT(--(SiteRange=Q$9),--(WeekRange=TrendWk2),--(AreaRange=$B154),Trend!$N$2:$N$1250)),(SUMPRODUCT(--(SiteRange=Q$9),--(WeekRange=TrendWk3),--(AreaRange=$B154),Trend!$N$2:$N$1250)))
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK
I guess one way would be to put the individual sumproduct formulas into three separate cells (eg A1, B1 and C1) and then work out your average as
Code:
=sum(A1:C1)/countif(A1:C1,">0")
There might be a more elegant solution . . .
 
Upvote 0
Or along the same lines:

=AVERAGE(IF(A1:C1<>0,A1:C1))

confirmed with ctrl+shift + enter as this is an array formula
 
Upvote 0

Forum statistics

Threads
1,214,646
Messages
6,120,717
Members
448,985
Latest member
chocbudda

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top