Related questions
Set Max value for color bar on seaborn heatmap
I need to set the max value on the seaborn heatmap cbar to 2. I've tried:
cbar_kws = { 'ticks' : [0, 2] }
sns.heatmap(tiles, robust=True, fmt="f", cmap= 'RdBu_r', cbar_kws = cbar_kws)
But this doesn't work and the documentation isn't …
One colorbar for seaborn heatmaps in subplot
Here is an example that shows a colorbar for each subplot:
import seaborn as sns
import matplotlib.pyplot as plt
import pandas as pd
import numpy as np
df = pd.DataFrame(np.random.random((10,10,)))
fig,axn = plt.subplots(2, 2, sharex=True, …
Data order in seaborn heatmap from pivot
So I have a heatmap created using seaborn
revels = rd.pivot("Flavour", "Packet number", "Contents")
ax = sns.heatmap(revels, annot=True, fmt="d", linewidths=0.4, cmap="YlOrRd")
plt.show()
which produces
There are two things which I want to do however, …