ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   AVE OR SUM (https://www.excelbanter.com/excel-discussion-misc-queries/228111-ave-sum.html)

Jesse

AVE OR SUM
 
I'm wondering if there is a formula that will omit a number from a table
when it is negative. If so, please inform me how to add it to a formula that
looks like this:
=sum(B2:b6)
Im import this data form other file and some times one of the cells come
with -99 which is not part of this calculation
Thanks.
B
70 70
72 -99
68 64
-99 -99
72 71


FSt1

AVE OR SUM
 
hi
try this
=SUMIF(B2:B6,"0",B2:B6)

regards
FSt1

"Jesse" wrote:

I'm wondering if there is a formula that will omit a number from a table
when it is negative. If so, please inform me how to add it to a formula that
looks like this:
=sum(B2:b6)
Im import this data form other file and some times one of the cells come
with -99 which is not part of this calculation
Thanks.
B
70 70
72 -99
68 64
-99 -99
72 71


Francis[_2_]

AVE OR SUM
 
Hi

Assuming your data start from A2, in A7, try this formula

=SUMIF(A2:A6,"0")

--
Hope this is helpful

Pls click the Yes button below if this post provide answer you have asked

Thank You

cheers, francis

Am not a greek but an ordinary user trying to assist another



"Jesse" wrote:

I'm wondering if there is a formula that will omit a number from a table
when it is negative. If so, please inform me how to add it to a formula that
looks like this:
=sum(B2:b6)
Im import this data form other file and some times one of the cells come
with -99 which is not part of this calculation
Thanks.
B
70 70
72 -99
68 64
-99 -99
72 71


Jesse

AVE OR SUM
 

Thanks. I tried it and it works.
"FSt1" wrote:

hi
try this
=SUMIF(B2:B6,"0",B2:B6)

regards
FSt1

"Jesse" wrote:

I'm wondering if there is a formula that will omit a number from a table
when it is negative. If so, please inform me how to add it to a formula that
looks like this:
=sum(B2:b6)
Im import this data form other file and some times one of the cells come
with -99 which is not part of this calculation
Thanks.
B
70 70
72 -99
68 64
-99 -99
72 71


Jesse

AVE OR SUM
 
Thanks Francis. I tried it and it works

"Francis" wrote:

Hi

Assuming your data start from A2, in A7, try this formula

=SUMIF(A2:A6,"0")

--
Hope this is helpful

Pls click the Yes button below if this post provide answer you have asked

Thank You

cheers, francis

Am not a greek but an ordinary user trying to assist another



"Jesse" wrote:

I'm wondering if there is a formula that will omit a number from a table
when it is negative. If so, please inform me how to add it to a formula that
looks like this:
=sum(B2:b6)
Im import this data form other file and some times one of the cells come
with -99 which is not part of this calculation
Thanks.
B
70 70
72 -99
68 64
-99 -99
72 71



All times are GMT +1. The time now is 03:58 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com