Fix dbg_mean_of()

Make sure we can use dbg_mean_of() to accumulate negative values too.