Fix dbg_mean_of() for negative numbers