changes to make the data display correctly and create a chart