home / github / issue_comments

Menu
  • GraphQL API
  • Search all tables

issue_comments: 459368801

This data as json

html_url issue_url id node_id user created_at updated_at author_association body reactions performed_via_github_app issue
https://github.com/pydata/xarray/pull/2729#issuecomment-459368801 https://api.github.com/repos/pydata/xarray/issues/2729 459368801 MDEyOklzc3VlQ29tbWVudDQ1OTM2ODgwMQ== 35968931 2019-01-31T14:42:28Z 2019-01-31T14:57:31Z MEMBER

Re complexity: It;s probably worth extracting everything to a animate_line function in animate.py?

I've had a go at that in the most recent commits.

I think this is a cool example, and lots of users will probably like it.

Great - it's definitely something I personally want to do all the time.

A high-level question: why was animatplot chosen over matplotlib's animation module?

Because animatplot already abstracts away the creation of the animation, so plotting an animation becomes almost a simple substitution matplotlib.plot.line() -> animatplot.blocks.Line().

Another advantage is that animatplot's block abstraction should make it easier to compose figures made of multiple animated plots, another thing people often want to do but is is awful with matplotlib.funcanimation directly.

(I haven't really looked at how animated facetgrids might work yet, but I suspect that being able to animate a large list of blocks would be helpful too.)

The logic is explained slightly more in #2355, and also looking at animatplot's docs might help you see why I think it's a good idea.

We don't have to use animatplot, but if we didn't I would be suggesting reimplementing something with a similar class structure in xarray as the best approach anyway. The disadvantages of using animatplot are that it's an extra (optional) dependency, and it's not got good unit test coverage yet so someone should probably contribute tests to animatplot upstream before xarray officially relies on it. animatplot isn't particularly large, so if we wanted to reimplement something similar in xarray then that would be feasible.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  404945709
Powered by Datasette · Queries took 2.013ms · About: xarray-datasette