Heatmap colour transitions on button press, code cleanup