Average formula

P

Pammy

I have a formula that gives me an answer of the number of days a case was
worked on. This column has 1500 rows, I want to take the 1500 rows of
numbers and generate an average in a cell at the top of the page.
Question, some of the rows contain a negative number and I do not want any
negative numbers to be reflected in the average formula. How can I create a
formula to average Column x3:x1500 and leave out the cells with the negative
numbers?

Thanks,
 
D

Dave Peterson

=sumif(x3:x1500,">=0") / countif(x3:x1500,">=0")

or maybe:

=if(countif(x3:x1500,">0")=0,"No data!",
sumif(x3:x1500,">=0") / countif(x3:x1500,">=0"))
 
Top