6

I'm trying to plot eigenbehaviors with matplotlib, basically I have a 2D matrix and would like to plot it with something very similar to a heat map, but the cells are divided and recognizable. See for example:

http://www.cl.cam.ac.uk/~nv240/pics/eigenbehaviour.jpg

marcorossi
  • 1,941
  • 2
  • 21
  • 34

1 Answers1

7

Is this what you are after?

enter image description here

from pylab import *

z = rand(10, 25)

c = pcolor(z)
set_cmap('hot')
colorbar()
c = pcolor(z, edgecolors='w', linewidths=1)
axis([0,25,0,10])
savefig('plt.png')
show()
fraxel
  • 34,470
  • 11
  • 98
  • 102