charts code moved to their own .js file
a little code cleanup
fixed bug with y scale in linear charts