Fix calculation of average flow size