state management: fixed api issues with scatterchart.js