Improved y-axis scaling

- Scaling of y-axis now only takes into y-values within the given x-axis
range (prevents bad scaling due to large/small numbers outside of
x-range)
Small fixes

- output to four letter formats (svgz etc.) fixed
- last fraction was not displayed, fixed