home / github

Menu
  • GraphQL API
  • Search all tables

issue_comments

Table actions
  • GraphQL API for issue_comments

16 rows where author_association = "CONTRIBUTOR" and issue = 340069538 sorted by updated_at descending

✖
✖
✖

✎ View and edit SQL

This data as json, CSV (advanced)

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

user 2

  • yohai 14
  • stickler-ci 2

issue 1

  • ENH: Scatter plots of one variable vs another · 16 ✖

author_association 1

  • CONTRIBUTOR · 16 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
519625567 https://github.com/pydata/xarray/pull/2277#issuecomment-519625567 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDUxOTYyNTU2Nw== yohai 6164157 2019-08-08T18:01:03Z 2019-08-08T18:01:03Z CONTRIBUTOR

Thanks @dcherian ! Glad to see this finally merged

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
518430365 https://github.com/pydata/xarray/pull/2277#issuecomment-518430365 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDUxODQzMDM2NQ== yohai 6164157 2019-08-05T22:51:00Z 2019-08-05T22:51:00Z CONTRIBUTOR

Thanks for this

On Mon, Aug 5, 2019 at 12:04 PM Deepak Cherian notifications@github.com wrote:

Yay, tests pass. I'll merge in a few days (cc @pydata/xarray https://github.com/orgs/pydata/teams/xarray, @yohai https://github.com/yohai )

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/pydata/xarray/pull/2277?email_source=notifications&email_token=ABPA5PNDIYQDJME4CUJREDDQDBFQNA5CNFSM4FJJSKRKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3SJCVA#issuecomment-518295892, or mute the thread https://github.com/notifications/unsubscribe-auth/ABPA5PMUANDUGDQKZHTIPYDQDBFQNANCNFSM4FJJSKRA .

-- Yohai Bar Sinai Post Doctoral Fellow John A. Paulson School of Engineering and Applied Sciences Harvard University

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
505053133 https://github.com/pydata/xarray/pull/2277#issuecomment-505053133 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDUwNTA1MzEzMw== yohai 6164157 2019-06-24T15:11:03Z 2019-06-24T15:11:03Z CONTRIBUTOR

@dcherian @shoyer I think it's ready to merge

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
504280891 https://github.com/pydata/xarray/pull/2277#issuecomment-504280891 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDUwNDI4MDg5MQ== yohai 6164157 2019-06-21T04:04:10Z 2019-06-21T04:04:10Z CONTRIBUTOR

turns out it was an easy fix. But now I wonder if we somehow screwed up other plotting functionalities without noticing (I checked a few but found nothing)

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
504276488 https://github.com/pydata/xarray/pull/2277#issuecomment-504276488 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDUwNDI3NjQ4OA== yohai 6164157 2019-06-21T03:35:49Z 2019-06-21T03:36:43Z CONTRIBUTOR

Hold the press! we can't merge. It seems like the new functionality messes up the faceted lineplots. If we define ds=xr.tutorial.scatter_example_dataset() then current behavior is :

ds.A.plot(col='x', row='w', hue='z'):

but with the pull request we screw up the legend

I need to look at this.

Also - kinda unsettling that this was not picked up by any unit test.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
504118360 https://github.com/pydata/xarray/pull/2277#issuecomment-504118360 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDUwNDExODM2MA== yohai 6164157 2019-06-20T17:43:14Z 2019-06-20T17:43:14Z CONTRIBUTOR

@dcherian @shoyer I can't seem to build the docs on my machine because of cartopy or something. Is there a way to access a built version from travis or something like that?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
504094593 https://github.com/pydata/xarray/pull/2277#issuecomment-504094593 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDUwNDA5NDU5Mw== yohai 6164157 2019-06-20T16:30:29Z 2019-06-20T17:07:55Z CONTRIBUTOR

I'll try to have a look tonight

On Thu, Jun 20, 2019, 11:30 Stephan Hoyer notifications@github.com wrote:

Tests seem to be failing due to lint errors, see #2277 (comment) https://github.com/pydata/xarray/pull/2277#issuecomment-447607250

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/pydata/xarray/pull/2277?email_source=notifications&email_token=ABPA5POP2JLG6ETE45NGEWDP3OPDBA5CNFSM4FJJSKRKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODYFYT2Y#issuecomment-504072683, or mute the thread https://github.com/notifications/unsubscribe-auth/ABPA5PN4I5RBWUDFYBCAZU3P3OPDBANCNFSM4FJJSKRA .

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
504054857 https://github.com/pydata/xarray/pull/2277#issuecomment-504054857 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDUwNDA1NDg1Nw== yohai 6164157 2019-06-20T14:46:14Z 2019-06-20T14:46:14Z CONTRIBUTOR

Anything I can do?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
469527459 https://github.com/pydata/xarray/pull/2277#issuecomment-469527459 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDQ2OTUyNzQ1OQ== yohai 6164157 2019-03-05T03:56:52Z 2019-03-05T03:56:52Z CONTRIBUTOR

Could we call this mark_size instead of scatter_size? The later sounds a little awkward to me.

I think matplotlib uses markersize

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
462211091 https://github.com/pydata/xarray/pull/2277#issuecomment-462211091 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDQ2MjIxMTA5MQ== yohai 6164157 2019-02-11T03:28:06Z 2019-02-11T03:40:25Z CONTRIBUTOR

My feeling is that "legend" applies to both a color bar and a discrete legend (or other more complicated stuff too) but I am not a native English speaker. I'm fine with whichever decision.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
460506195 https://github.com/pydata/xarray/pull/2277#issuecomment-460506195 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDQ2MDUwNjE5NQ== yohai 6164157 2019-02-05T04:09:49Z 2019-02-05T04:13:35Z CONTRIBUTOR

This looks great! Thanks @dcherian!

The only comment I have is with respect to the part of the API that specifies whether a legend should be drawn or not. For non-numerical hues (or when hue_style='discrete') the legend is turned off by add_legend=False but for numerical ones by add_colorbar=False, which might be not intuitive and might require manual editing in various places if you change your mind between a discrete and continuous legend. I would suggest to either unify both options to one, or make them interchangeable (if not contradicting).

something like:

python if xor(add_legend, add_colorbar): #decide according to plot type: if it's non-numeric or `hue_style='discrete'` # then use value of add_legend, else use value of add_colorbar elif add_legend or add_colorbar: #plot legend according to current logic

but really there should only be one allowable keyword here I think

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
439954393 https://github.com/pydata/xarray/pull/2277#issuecomment-439954393 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDQzOTk1NDM5Mw== yohai 6164157 2018-11-19T16:28:11Z 2018-11-19T16:28:11Z CONTRIBUTOR

@dcherian thanks for nudging. Actually I'm in a pretty stressed time now. I will be able to pick this up in a few months, but I wouldn't mind if someone else does it in the meantime (I don't think there's a lot of work there)

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
407076380 https://github.com/pydata/xarray/pull/2277#issuecomment-407076380 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDQwNzA3NjM4MA== yohai 6164157 2018-07-23T14:25:17Z 2018-07-23T14:25:17Z CONTRIBUTOR

thanks @dcherian for the review. I'll fix the code when I get to it later this week,

Regarding the size and marker style - I'm not sure it makes sense to duplicate this functionality. Is it not easier to stack the two data arrays into one, use to_pandas and then just use seaborn directly? The reason I started this PR in the first place is that I happened to do relatively simple scatter plots quite often, so I thought it'd be handy. but for more elaborate ones I would use a dedicated tool like seaborn.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
405447950 https://github.com/pydata/xarray/pull/2277#issuecomment-405447950 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDQwNTQ0Nzk1MA== yohai 6164157 2018-07-17T03:26:20Z 2018-07-17T03:26:20Z CONTRIBUTOR

I don't have an opinion about naming variables and would be happy with whatever decision y'all make.

For the code -- I added tests and changed the logic a bit. Following @dcherian's suggestion, now the default behavior is no longer coloring hues with discrete values (legend) but rather with a continuous scale (colorbar). It does make actually more sense and I think it should also be the default behavior for regular line plots. This is the API now:

python A = xr.DataArray(np.zeros([3, 20, 4, 4]), dims=[ 'x', 'y', 'z', 'w'], coords=[np.sort(np.random.randn(k)) for k in [3,20,4,4]]) ds=xr.Dataset({'A': A.x+A.y+A.z+A.w, 'B': -0.2/A.x-2.3*A.y-np.abs(A.z)**0.123+A.w**2}) ds.A.attrs['units'] = 'Aunits' ds.B.attrs['units'] = 'Bunits' ds.z.attrs['units'] = 'Zunits' ds.plot.scatter(x='A', y='B')

Specifying hue creates a colorbar: python ds.plot.scatter(x='A',y='B', hue='z') If, however, the hue dimension is not numeric, then a legend is created: python ds['z']= ['who', 'let','dog','out'] ds.plot.scatter(x='A',y='B', hue='z')

If you want a discrete legend even for numeric hues, you can specify it explicitly: python ds.plot.scatter(x='A',y='B', hue='w', discrete_legend=True)

I am a bit bothered by the fact that this is not only a different coloring method, it's a very different style altogether (under the hood using plot instead of scatter). I don't know if it's a good thing or a bad thing that the same function can produce very different looking figures. Input will be welcome about that.

Of course, faceting works as you think it should: python ds.plot.scatter(x='A',y='B', hue='z',col='x') ds.plot.scatter(x='A',y='B', hue='w',col='x', col_wrap=2)

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
404161728 https://github.com/pydata/xarray/pull/2277#issuecomment-404161728 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDQwNDE2MTcyOA== stickler-ci 16011037 2018-07-11T13:05:26Z 2018-07-11T13:05:26Z CONTRIBUTOR

Could not review pull request. It may be too large, or contain no reviewable changes.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538
404024984 https://github.com/pydata/xarray/pull/2277#issuecomment-404024984 https://api.github.com/repos/pydata/xarray/issues/2277 MDEyOklzc3VlQ29tbWVudDQwNDAyNDk4NA== stickler-ci 16011037 2018-07-11T02:31:09Z 2018-07-11T02:31:09Z CONTRIBUTOR

Could not review pull request. It may be too large, or contain no reviewable changes.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  ENH: Scatter plots of one variable vs another 340069538

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 15.317ms · About: xarray-datasette
  • Sort ascending
  • Sort descending
  • Facet by this
  • Hide this column
  • Show all columns
  • Show not-blank rows