improve charts

improve range calcuation