PDA

View Full Version : Exclude 0 mAh values from average computations


TheBum
09-17-2009, 11:12 PM
The subject says it all. I sometimes don't enter a value, especially if I forget to time a flight. Including the 0 values just skews the data.

gregt
09-18-2009, 03:33 AM
The subject says it all. I sometimes don't enter a value, especially if I forget to time a flight. Including the 0 values just skews the data.

I'll double check it, but I'm pretty sure I'm throwing out null and 0 values before averaging.

gregt
09-18-2009, 03:42 AM
Yep. I thought I had thought of that. ;)

select avg(mah) mahs
from flights
where battery_id = $bid
and mah > 0

TheBum
10-02-2009, 11:12 PM
OK, thanks. I thought that I had some skew on my averages due to the 0 values, but I guess not.