Setting Y axis boundaries dynamically based on the values