fixes bug introduced in one of today's commits - wrong condition led to avg=0 records not being output