Reputation: 167
I have created a matrix:
s1=np.random.randn(1000,1000)
v1=la.eigvals(s1)
matrix1=np.matrix(v1)
I want to plot the matrix in ipython
.
What appropriate matplotlib
function should I use?
Upvotes: 0
Views: 514
Reputation: 88158
A very simple example to "plot" a matrix:
import numpy as np
import pylab as plt
S = np.random.randn(100,100)
# Make symmetric so everything is real
S += S.T
W,V = np.linalg.eigh(S)
import pylab as plt
plt.imshow(V,interpolation="none")
plt.show()
Upvotes: 1