handle bad addr balance lookup
fix avg line
fix doantion efficiency