{=AVERAGE(IF(C10:H10<>0,c10:h10)}

aka_krakur

Active Member
Joined
Jan 31, 2006
Messages
438
I am able to use {=AVERAGE(IF(C10:H10<>0,c10:h10)} to get the average between cells excluding values of zero.
I need help using this same thought process but using a running average between worksheets (still eliminating values of zero).

I've tried using:
{=AVERAGE(IF(C10:H10,'Wk 1 - P'!C10:H10<>0,(C10:H10,'Wk 1 - P'!C10:H10)))}
but I get an Excel help box that pops up stating: "You've entered too many arguments for this function....."

1. Can anyone help
2. Is it even possible to write a formula for such a task as this?
 
Sorry Sorry I got what you are saying now!!
try:
=SUM('Wk 1 - P:Wk 4 - P'!B10)/=COUNTIF('Wk 3 - P'!C10:H10,">0")+COUNTIF('Wk 4 - P'!C10:H10,">0")+COUNTIF('Wk 2 - P'!C10:H10,">0")+COUNTIF('Wk 1 - P'!C10:H10,">0")

There is probably an easier way but I got this to work

Michael
 
Upvote 0

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.
Let A1:A4 contain a list of your sheet names...

Wk 1 - P
Wk 2 - P
Wk 3 - P
Wk 4 - P

Then, try the following formula...

=SUMPRODUCT(SUMIF(INDIRECT("'"&$A$1:$A$4&"'!C10:H10"),">0"))/SUMPRODUCT(COUNTIF(INDIRECT("'"&$A$1:$A$4&"'!C10:H10"),">0"))
THAT WORKED!! THANKS!!!
 
Upvote 0
=SUMPRODUCT(SUMIF(INDIRECT("'"&$A$1:$A$4&"'!C10:H10"),">0"))/SUMPRODUCT(COUNTIF(INDIRECT("'"&$A$1:$A$4&"'!C10:H10"),">0"))

yeah!!! that worked. followed those instructions and boom, it worked.

Thanks
 
Upvote 0

Forum statistics

Threads
1,216,462
Messages
6,130,781
Members
449,591
Latest member
sharmavishnu413

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