fix to csv file, divide by zero handling for aggregate averages