Simpliefied chart creation and wrote tests.