Excel Formula Situation Again


Posted by Jason White on December 29, 2000 1:30 PM


I'm trying to get an average, but I can't seem to get it right.

....Gas Price
1....$1.45
2....
3....$1.22
4....$1.58
5....
6....
7....$1.23
8....
9....=Average

I've tried =AVERAGE(A1:A8) But that give me some HUGE number in the thousands.

How do I get it to look for the cells w/ data, add them and then devide them by the number of entries it found?

Jason

Posted by Jason White on December 29, 2000 1:45 PM

Nevermind everyone....I think I've got it:

=SUM(F5:F35)/COUNTIF(F5:F35,">0")

That seems to do the trick



Posted by Bruce on December 29, 2000 2:18 PM

You could also try
{=AVERAGE(IF(F5:F35>0,F5:F35))} , but don't type the "{}", just hit ctrl-shift-enter