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/1785#issuecomment-354615219,https://api.github.com/repos/pydata/xarray/issues/1785,354615219,MDEyOklzc3VlQ29tbWVudDM1NDYxNTIxOQ==,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}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-354615135,https://api.github.com/repos/pydata/xarray/issues/1785,354615135,MDEyOklzc3VlQ29tbWVudDM1NDYxNTEzNQ==,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}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-354612770,https://api.github.com/repos/pydata/xarray/issues/1785,354612770,MDEyOklzc3VlQ29tbWVudDM1NDYxMjc3MA==,2448579,2017-12-31T16:26:29Z,2017-12-31T16:26:29Z,MEMBER,@shoyer Used your suggested change.,"{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-352918289,https://api.github.com/repos/pydata/xarray/issues/1785,352918289,MDEyOklzc3VlQ29tbWVudDM1MjkxODI4OQ==,2448579,2017-12-19T23:29:25Z,2017-12-19T23:29:25Z,MEMBER,"@shoyer , @fmaussion : Updated to require either `x` or `hue` kwarg if input is 2D.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-352888557,https://api.github.com/repos/pydata/xarray/issues/1785,352888557,MDEyOklzc3VlQ29tbWVudDM1Mjg4ODU1Nw==,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}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-352619693,https://api.github.com/repos/pydata/xarray/issues/1785,352619693,MDEyOklzc3VlQ29tbWVudDM1MjYxOTY5Mw==,2448579,2017-12-19T02:20:42Z,2017-12-19T02:20:42Z,MEMBER,"I've added support for a `hue` kwarg in the latest commit. Let me know what you think.
> 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.)
Well, this behaviour is analogous to automatically choosing `x,y` in `_plot2d`. xarray is already pretty opinionated in this respect.
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.
Re:error, would that be a message stating that either `x` or `hue` be specified if the input is 2D?","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-352618585,https://api.github.com/repos/pydata/xarray/issues/1785,352618585,MDEyOklzc3VlQ29tbWVudDM1MjYxODU4NQ==,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}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-352616868,https://api.github.com/repos/pydata/xarray/issues/1785,352616868,MDEyOklzc3VlQ29tbWVudDM1MjYxNjg2OA==,2448579,2017-12-19T02:02:10Z,2017-12-19T02:02:10Z,MEMBER,@shoyer `hue` sounds perfect. I'll work on adding that.,"{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-352616597,https://api.github.com/repos/pydata/xarray/issues/1785,352616597,MDEyOklzc3VlQ29tbWVudDM1MjYxNjU5Nw==,2448579,2017-12-19T02:00:31Z,2017-12-19T02:00:31Z,MEMBER,"@fmaussion I've added one more commit. 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.
Extended an existing test
","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-352616524,https://api.github.com/repos/pydata/xarray/issues/1785,352616524,MDEyOklzc3VlQ29tbWVudDM1MjYxNjUyNA==,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}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-352203031,https://api.github.com/repos/pydata/xarray/issues/1785,352203031,MDEyOklzc3VlQ29tbWVudDM1MjIwMzAzMQ==,2448579,2017-12-16T18:48:02Z,2017-12-16T18:48:02Z,MEMBER,@fmaussion I've added more tests. Let me know if you'd like more changes.,"{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-352181503,https://api.github.com/repos/pydata/xarray/issues/1785,352181503,MDEyOklzc3VlQ29tbWVudDM1MjE4MTUwMw==,10050469,2017-12-16T12:48:40Z,2017-12-16T12:48:40Z,MEMBER,"Looks quite good! Thanks.
Sorry to be annoying ;), but there should be tests for the features you document:
> + x : string, optional
> + Coordinate for x axis (2D inputs only). If None use darray.dims[1]
> + add_legend : boolean, optional
> + Add legend with y axis coordinates (2D inputs only).
Currently, choosing another dim for the x axis and the legend kwargs are not tested.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,282339218
https://github.com/pydata/xarray/pull/1785#issuecomment-352097776,https://api.github.com/repos/pydata/xarray/issues/1785,352097776,MDEyOklzc3VlQ29tbWVudDM1MjA5Nzc3Ng==,2448579,2017-12-15T19:58:11Z,2017-12-15T19:58:11Z,MEMBER,"Now adds a legend too. Can be turned off with `add_legend=False`

","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,282339218