home / github

Menu
  • GraphQL API
  • Search all tables

issue_comments

Table actions
  • GraphQL API for issue_comments

3 rows where author_association = "MEMBER" and issue = 423016453 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

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

user 2

  • shoyer 2
  • max-sixty 1

issue 1

  • Dataset.from_records()? · 3 ✖

author_association 1

  • MEMBER · 3 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
840809933 https://github.com/pydata/xarray/issues/2824#issuecomment-840809933 https://api.github.com/repos/pydata/xarray/issues/2824 MDEyOklzc3VlQ29tbWVudDg0MDgwOTkzMw== max-sixty 5635139 2021-05-13T20:20:52Z 2021-05-13T20:20:52Z MEMBER

For any future travelers who come across this: a slight twist on the patterns above is xr.Dataset({name: (("dim",), my_recarray[name]) for name in my_recarray.dtype.names}) — the data will be loaded on a single dimension, and then .set_index(dim=['a','b']) can be used to set the appropriate indexes vs variables.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Dataset.from_records()? 423016453
474686642 https://github.com/pydata/xarray/issues/2824#issuecomment-474686642 https://api.github.com/repos/pydata/xarray/issues/2824 MDEyOklzc3VlQ29tbWVudDQ3NDY4NjY0Mg== shoyer 1217238 2019-03-20T05:09:10Z 2019-03-20T05:09:10Z MEMBER

We could potentially pick dimension names automatically, but it's not an entirely obvious this to do since passing a dict of numpy arrays into the xarray.Dataset constructor isn't supported (but I guess we could support that).

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Dataset.from_records()? 423016453
474645059 https://github.com/pydata/xarray/issues/2824#issuecomment-474645059 https://api.github.com/repos/pydata/xarray/issues/2824 MDEyOklzc3VlQ29tbWVudDQ3NDY0NTA1OQ== shoyer 1217238 2019-03-20T01:13:36Z 2019-03-20T01:13:36Z MEMBER

Turning a record array into a dict of arrays is pretty straightforward, e.g., arrays = {name: my_recarray[name] for name in my_recarray.dtype.names}

You could then pass this into xr.Dataset, but you'll also have to set dimension names.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Dataset.from_records()? 423016453

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 11.839ms · About: xarray-datasette