home / github

Menu
  • GraphQL API
  • Search all tables

issue_comments

Table actions
  • GraphQL API for issue_comments

11 rows where issue = 409618228 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

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

user 4

  • kmsquire 6
  • naught101 2
  • shoyer 2
  • pep8speaks 1

author_association 3

  • CONTRIBUTOR 6
  • NONE 3
  • MEMBER 2

issue 1

  • Add `Dataset.drop_dims` · 11 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
482468492 https://github.com/pydata/xarray/pull/2767#issuecomment-482468492 https://api.github.com/repos/pydata/xarray/issues/2767 MDEyOklzc3VlQ29tbWVudDQ4MjQ2ODQ5Mg== naught101 167164 2019-04-12T07:26:07Z 2019-04-12T07:26:07Z NONE

I guess ds = ds.drop([c for c in ds.coords if c not in ds.dims]) works. Might be nice to have a convenience function for that though.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add `Dataset.drop_dims` 409618228
482468103 https://github.com/pydata/xarray/pull/2767#issuecomment-482468103 https://api.github.com/repos/pydata/xarray/issues/2767 MDEyOklzc3VlQ29tbWVudDQ4MjQ2ODEwMw== naught101 167164 2019-04-12T07:24:43Z 2019-04-12T07:24:43Z NONE

Is there currently a way to drop unused coordinates, like this?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add `Dataset.drop_dims` 409618228
469088112 https://github.com/pydata/xarray/pull/2767#issuecomment-469088112 https://api.github.com/repos/pydata/xarray/issues/2767 MDEyOklzc3VlQ29tbWVudDQ2OTA4ODExMg== kmsquire 223250 2019-03-04T01:22:04Z 2019-03-04T01:22:04Z CONTRIBUTOR

No worries--thanks for merging!

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add `Dataset.drop_dims` 409618228
469056558 https://github.com/pydata/xarray/pull/2767#issuecomment-469056558 https://api.github.com/repos/pydata/xarray/issues/2767 MDEyOklzc3VlQ29tbWVudDQ2OTA1NjU1OA== shoyer 1217238 2019-03-03T19:43:11Z 2019-03-03T19:43:11Z MEMBER

thanks @kmsquire, especially for your patience here!

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add `Dataset.drop_dims` 409618228
468980810 https://github.com/pydata/xarray/pull/2767#issuecomment-468980810 https://api.github.com/repos/pydata/xarray/issues/2767 MDEyOklzc3VlQ29tbWVudDQ2ODk4MDgxMA== kmsquire 223250 2019-03-03T02:28:02Z 2019-03-03T02:28:02Z CONTRIBUTOR

Rebased to fix the NEWS conflict.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add `Dataset.drop_dims` 409618228
463050831 https://github.com/pydata/xarray/pull/2767#issuecomment-463050831 https://api.github.com/repos/pydata/xarray/issues/2767 MDEyOklzc3VlQ29tbWVudDQ2MzA1MDgzMQ== pep8speaks 24736507 2019-02-13T04:15:14Z 2019-03-03T02:27:43Z NONE

Hello @kmsquire! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! :beers:

Comment last updated at 2019-03-03 02:27:43 UTC
{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add `Dataset.drop_dims` 409618228
467568430 https://github.com/pydata/xarray/pull/2767#issuecomment-467568430 https://api.github.com/repos/pydata/xarray/issues/2767 MDEyOklzc3VlQ29tbWVudDQ2NzU2ODQzMA== kmsquire 223250 2019-02-26T19:02:23Z 2019-02-26T19:02:23Z CONTRIBUTOR

@shoyer I force pushed the requested changes. Please let me know if there is anything else. Thanks!

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add `Dataset.drop_dims` 409618228
466463669 https://github.com/pydata/xarray/pull/2767#issuecomment-466463669 https://api.github.com/repos/pydata/xarray/issues/2767 MDEyOklzc3VlQ29tbWVudDQ2NjQ2MzY2OQ== kmsquire 223250 2019-02-22T16:47:11Z 2019-02-22T16:47:11Z CONTRIBUTOR

I agree that it makes sense to recompute dimensions from variables.

Okay, that's what this PR already did (via the call to _replace_with_new_dims).

Rebased on master. From my perspective, this should be good to go.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add `Dataset.drop_dims` 409618228
466239515 https://github.com/pydata/xarray/pull/2767#issuecomment-466239515 https://api.github.com/repos/pydata/xarray/issues/2767 MDEyOklzc3VlQ29tbWVudDQ2NjIzOTUxNQ== shoyer 1217238 2019-02-22T01:41:41Z 2019-02-22T01:41:41Z MEMBER

It's OK to use _replace_with_new_dims still. I think we'll eventually replace it in favor of _replace_with_new_dims but we aren't there yet.

I agree that it makes sense to recompute dimensions from variables. There's not much point in keeping around extra dimensions that don't have corresponding variables, and I'm pretty sure that this is consistent with how Dataset.drop() works.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add `Dataset.drop_dims` 409618228
466083575 https://github.com/pydata/xarray/pull/2767#issuecomment-466083575 https://api.github.com/repos/pydata/xarray/issues/2767 MDEyOklzc3VlQ29tbWVudDQ2NjA4MzU3NQ== kmsquire 223250 2019-02-21T17:11:05Z 2019-02-21T17:11:05Z CONTRIBUTOR

@shoyer I'm sure you're busy... wondering if you might have time to review this (or direct it to someone else to review)? Other than my question above, it should be pretty straightforward.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add `Dataset.drop_dims` 409618228
463078403 https://github.com/pydata/xarray/pull/2767#issuecomment-463078403 https://api.github.com/repos/pydata/xarray/issues/2767 MDEyOklzc3VlQ29tbWVudDQ2MzA3ODQwMw== kmsquire 223250 2019-02-13T06:38:43Z 2019-02-13T06:38:43Z CONTRIBUTOR

I was looking for this functionality and ran across #1949.

There was one bit of behavior that was unclear to me. Say I have

```python In [6]: data = xr.Dataset({'A': (['x', 'y'], np.random.randn(2, 3)), ...: 'B': ('x', np.random.randn(2)), ...: 'x': ['a', 'b'], 'z': np.pi})

In [7]: data Out[7]: <xarray.Dataset> Dimensions: (x: 2, y: 3) Coordinates: * x (x) <U1 'a' 'b' Dimensions without coordinates: y Data variables: A (x, y) float64 -0.662 -0.705 -0.1866 -0.8655 0.5816 -0.2308 B (x) float64 -0.1002 2.402 z float64 3.142

In [8]: data.drop_dims('x') Out[8]: <xarray.Dataset> Dimensions: () Data variables: z float64 3.142 ```

In this case, I dropped x, but because that eliminated variable A, I also dropped my y dimension, since A was the only variable using y.

At one point, I implemented this slightly differently, which instead gave

python In [8]: data.drop_dims('x') Out[8]: <xarray.Dataset> Dimensions: (y: 3) Dimensions without coordinates: y Data variables: z float64 3.142

In some ways, this seems preferable, especially if y has coordinates. The only downside I can see is that this version called Dataset._replace_vars_and_dims(), the docstring for which says it's deprecated (although it's still widely used).

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add `Dataset.drop_dims` 409618228

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