Hello , i have the following code in matlab and trying to do it in
matplotlib.
I have this code in matlab (in a function showGraphs):
...
m = size(myList, 3);
for k = 1:m
g = myList(:, :, k);
image(g + 1)
axis off
axis square
M(k) = getframe;
end;
and in another file (another function):
...
M = showGraphs(grids)
movie(M, 1)
I did so far:
def showGraphs(data):
data=sc.array([data])
n=sc.shape(data)[2]
for k in range(n):
mydata=data[:,:,k]
#plt.imshow(mydata+1) -->> this doesn't work
Also ,in order to do the animation :
grids=...(result from another function)
result=showGraph(grids)
fig=plt.figure()
ani=animation.FuncAnimation(fig,result,interval=30,blit=True)
plt.show()
Right now the program says "TypeError: 'NoneType' object is not
callable" (it has errors in the animation call)
What should be my approach to this in order to have the animation?
Thank you!
------------------------------------------------------------------------------
Try before you buy = See our experts in action!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-dev2
_______________________________________________
Matplotlib-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-users