0

I want to plot a heatmap with something like status bar.

What I want to plot is exactly here.

heatmap with status bar

Above heatmap, there is the bar(red and blue).

I found this bar can be created with ColSideColors in R.

But I cannot find the way to do this in Python.

If anyone knows the way, please tell me...!

himkt
  • 31
  • 4
  • So what are you after? The heatmap or the status bar? would be good if you have codes of what you have done though. – TuanDT Sep 15 '16 at 03:44
  • Pretty sure that is called a dendogram. `scipy` and I think `seaborn` have code for plotting them – tacaswell Sep 15 '16 at 03:47
  • > Tuan333 thanks to comment ! now, i write a code like bellow. ```python data = random((10, 10)) fig, ax = pyplot.subplots() heatmap = ax.pcolor(data) ax.set_xticks(arange(data.shape[0]) + 0.5, minor=False) ax.set_yticks(arange(data.shape[1]) + 0.5, minor=False) ax.invert_yaxis() ax.xaxis.tick_top() pyplot.show() ``` – himkt Sep 15 '16 at 03:55
  • > tacaswell thanks to comment ! now, I use matplotlib.pcolor() or seaborn.heatmap() but I cannot find the way to plot the bar (under the dendrogram) and heatmap together... – himkt Sep 15 '16 at 04:04
  • I found the article which seems to be related in this task. http://stackoverflow.com/questions/27988846/how-to-express-classes-on-the-axis-of-a-heatmap-in-seaborn Thanks to advices ! – himkt Sep 15 '16 at 12:45

0 Answers0