home / github

Menu
  • GraphQL API
  • Search all tables

issue_comments

Table actions
  • GraphQL API for issue_comments

5 rows where author_association = "MEMBER", issue = 282339218 and user = 1217238 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

Suggested facets: reactions, created_at (date), updated_at (date)

user 1

  • shoyer · 5 ✖

issue 1

  • plot.line(): Draw multiple lines for 2D DataArrays. · 5 ✖

author_association 1

  • MEMBER · 5 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
354615219 https://github.com/pydata/xarray/pull/1785#issuecomment-354615219 https://api.github.com/repos/pydata/xarray/issues/1785 MDEyOklzc3VlQ29tbWVudDM1NDYxNTIxOQ== shoyer 1217238 2017-12-31T17:18:19Z 2017-12-31T17:18:19Z MEMBER

I merged this, but it might also be nice to add an example (or at least brief mention) to the narrative docs for 1D plotting. See: http://xarray.pydata.org/en/stable/plotting.html#one-dimension https://github.com/pydata/xarray/blob/master/doc/plotting.rst

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  plot.line(): Draw multiple lines for 2D DataArrays. 282339218
354615135 https://github.com/pydata/xarray/pull/1785#issuecomment-354615135 https://api.github.com/repos/pydata/xarray/issues/1785 MDEyOklzc3VlQ29tbWVudDM1NDYxNTEzNQ== shoyer 1217238 2017-12-31T17:16:22Z 2017-12-31T17:16:22Z MEMBER

Thanks!

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  plot.line(): Draw multiple lines for 2D DataArrays. 282339218
352888557 https://github.com/pydata/xarray/pull/1785#issuecomment-352888557 https://api.github.com/repos/pydata/xarray/issues/1785 MDEyOklzc3VlQ29tbWVudDM1Mjg4ODU1Nw== shoyer 1217238 2017-12-19T21:15:13Z 2017-12-19T21:15:13Z MEMBER

Well, this behaviour is analogous to automatically choosing x,y in _plot2d. xarray is already pretty opinionated in this respect.

We use the order of the dimensions on the array for choosing how to plot it. The analogous behavior would be to always plot longer dimension along the x-axis, which isn't what we do.

The current behaviour for a 10000x3 array is to plot 10000 lines which is bad. I'm OK with adding an error message but strongly feel that choosing to plot 3 lines (i.e. always smallest number of lines) is a good default.

I agree that users probably rarely want 10,000 lines :). That's a good reason to require an explicit choice here.

The problem are edge cases like a 5x6 array. Do you want 5 lines of 6 points each or 6 lines of 5 points each? If we make the heuristic depend on the size of the array, then it will give very hard to understand what happens when the array shape changes slightly.

Re:error, would that be a message stating that either x or hue be specified if the input is 2D?

Yes, that sounds right.

{
    "total_count": 1,
    "+1": 1,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  plot.line(): Draw multiple lines for 2D DataArrays. 282339218
352618585 https://github.com/pydata/xarray/pull/1785#issuecomment-352618585 https://api.github.com/repos/pydata/xarray/issues/1785 MDEyOklzc3VlQ29tbWVudDM1MjYxODU4NQ== shoyer 1217238 2017-12-19T02:13:09Z 2017-12-19T02:13:09Z MEMBER

If x kwarg is not provided, we automatically choose the longer dimension. So if you have a 10000x3 DataArray, this will plot 3 lines instead of 10000.

I am very nervous about automated heuristics for choosing behavior. I would much rather we raise an error message in cases like this, rather than guessing. (The problem is that heuristics can make it very hard to predict/understand how code will work without trying it.)

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  plot.line(): Draw multiple lines for 2D DataArrays. 282339218
352616524 https://github.com/pydata/xarray/pull/1785#issuecomment-352616524 https://api.github.com/repos/pydata/xarray/issues/1785 MDEyOklzc3VlQ29tbWVudDM1MjYxNjUyNA== shoyer 1217238 2017-12-19T02:00:07Z 2017-12-19T02:00:07Z MEMBER

Is there a keyword argument name that it would make sense to use for the dimension that is repeated into multiple lines? Maybe hue, as is used by Seaborn?

I would like there to be a fully explicit way to make these plots.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  plot.line(): Draw multiple lines for 2D DataArrays. 282339218

Advanced export

JSON shape: default, array, newline-delimited, object

CSV options:

CREATE TABLE [issue_comments] (
   [html_url] TEXT,
   [issue_url] TEXT,
   [id] INTEGER PRIMARY KEY,
   [node_id] TEXT,
   [user] INTEGER REFERENCES [users]([id]),
   [created_at] TEXT,
   [updated_at] TEXT,
   [author_association] TEXT,
   [body] TEXT,
   [reactions] TEXT,
   [performed_via_github_app] TEXT,
   [issue] INTEGER REFERENCES [issues]([id])
);
CREATE INDEX [idx_issue_comments_issue]
    ON [issue_comments] ([issue]);
CREATE INDEX [idx_issue_comments_user]
    ON [issue_comments] ([user]);
Powered by Datasette · Queries took 252.162ms · About: xarray-datasette