Averages with conditions....

S

Scott A

Hello,

I need serious help with a couple of formulas.

1st- I am trying to average a row of numbers but need it to not include
numbers in that crtain row if row 7 & 9 are both zeros in that specific
column (I need to do this for rows 7 & 9 - cells G7 & G9). Is there a way to
do this?

2nd- The dollar amounts in row 10 come from other sheets. I would also like
it to only average the amounts if 7 & 9 are not both zeros.


A B C D E
F G
6 Date 12/5/08 12/5/08 12/5/08 12/5/08 12/5/08
Averages
7 Rehab Count 3 4 3 0
0 2.50
8
9 Demo Count 5 7 1 3
0 4.00
10 Costs $670.72 $880.64 $562.35 $539.31 $0.00
$663.25


Thank or any help you can provide!

Scott A
 
S

smartin

Scott said:
Hello,

I need serious help with a couple of formulas.

1st- I am trying to average a row of numbers but need it to not include
numbers in that crtain row if row 7 & 9 are both zeros in that specific
column (I need to do this for rows 7 & 9 - cells G7 & G9). Is there a way to
do this?

2nd- The dollar amounts in row 10 come from other sheets. I would also like
it to only average the amounts if 7 & 9 are not both zeros.


A B C D E
F G
6 Date 12/5/08 12/5/08 12/5/08 12/5/08 12/5/08
Averages
7 Rehab Count 3 4 3 0
0 2.50
8
9 Demo Count 5 7 1 3
0 4.00
10 Costs $670.72 $880.64 $562.35 $539.31 $0.00
$663.25


Thank or any help you can provide!

Scott A


Try this array* formula for average of cells in row 7:
=AVERAGE(IF(B7:F7+B9:F9<>0,B7:F7))

Replace the final "B7:F7" with "B9:F9" or "B10:F10" for the other two.

*Array formulas must be committed by pressing Ctrl+Shift+Enter, do not
just press Enter or Tab.
 
S

Scott A

That worked great, Thank you!

smartin said:
Try this array* formula for average of cells in row 7:
=AVERAGE(IF(B7:F7+B9:F9<>0,B7:F7))

Replace the final "B7:F7" with "B9:F9" or "B10:F10" for the other two.

*Array formulas must be committed by pressing Ctrl+Shift+Enter, do not
just press Enter or Tab.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top