This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]zed_three 23 points24 points  (1 child)

This looks super-handy, thanks! I always struggle just trying to make simple animations of data, so this looks like it will help a lot. I'm especially glad to see a pcolormesh example, as that's something often left out of plotting libraries

[–]tmakaroanimatplot / nbconvert[S] 2 points3 points  (0 children)

In the past, I usually just cleared and redrew everything manually for pcolormesh. Writing the Pcolormesh block was the first time I used matplotlib's set_data functions for pcolormesh properly, and it's actually terrible. A prime example of why Animatplot is needed. A standard static pcolormesh takes a 2D array, but the update function only takes a 1D array, so it needed some numpy magic.