Apply seaborn heatmap columnwise on pandas dataframe
问题 I was trying to use a heatmap form seaborn on a pivoted pandas dataframe like in the hyperlink which works df = pd.DataFrame(np.random.randint(1,100,size = (3,2))) df.columns = ['A','B'] df sns.heatmap(df, annot=True, fmt="d", linewidths=.5,cmap="RdYlGn") Output of code block - Entire Dataframe formatted as single heatmap The output picks 45 as min and 86 as max and color codes the entire dataframe But what i was unable to do was to apply the heatmap column wise i.e. like conditional