moved formatDataForChart into Visualisation model