heatmap functions start