Animation Using Matplotlib With Subplots And Artistanimation
I am working on an image analysis and I want to create an animation of the final results that includes the time-sequence of 2D data and a plot of the time sequences at a single pix
Solution 1:
plot
returns a list of artists (hence why the error is referring to a list). This is so you can call plot
like lines = plot(x1, y1, x2, y2,...)
.
Change
im2 = ax2.plot(image[0:time,5,5])
to
im2, = ax2.plot(image[0:time,5,5])
Adding the comma un-packs the length one list into im2
As for you second question, we try to only have one question per thread on SO so please open a new question.
Post a Comment for "Animation Using Matplotlib With Subplots And Artistanimation"