home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

3 rows where issue = 250751931 sorted by updated_at descending

✖
✖

✎ View and edit SQL

This data as json, CSV (advanced)

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

user 3

  • jhamman 1
  • darothen 1
  • betaplane 1

author_association 2

  • NONE 2
  • MEMBER 1

issue 1

  • Unexpected behavior with DataArray.resample(how='sum') in presence of NaNs · 3 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
323105006 https://github.com/pydata/xarray/issues/1509#issuecomment-323105006 https://api.github.com/repos/pydata/xarray/issues/1509 MDEyOklzc3VlQ29tbWVudDMyMzEwNTAwNg== darothen 4992424 2017-08-17T15:20:22Z 2017-08-17T15:20:22Z NONE

@betaplane a re-factoring of the resample API to match pandas' is currently being wrapped up and slated for 0.10.0; see #1272

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Unexpected behavior with DataArray.resample(how='sum') in presence of NaNs 250751931
322926397 https://github.com/pydata/xarray/issues/1509#issuecomment-322926397 https://api.github.com/repos/pydata/xarray/issues/1509 MDEyOklzc3VlQ29tbWVudDMyMjkyNjM5Nw== betaplane 5564291 2017-08-16T23:23:38Z 2017-08-16T23:23:38Z NONE

Ok, thanks a lot. Just as a comment though, pandas does it differently, and the xarray documentation states that "resample uses essentially the same api as resample in pandas." ``` In [1]: import numpy as np

In [2]: import pandas as pd

In [3]: x = pd.DataFrame([1, np.nan], pd.date_range('2017-08-01', '2017-08-02'))

In [4]: x.resample('D').mean() Out[4]: 0 2017-08-01 1.0 2017-08-02 NaN

In [5]: x.resample('D').sum() Out[5]: 0 2017-08-01 1.0 2017-08-02 NaN ```

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Unexpected behavior with DataArray.resample(how='sum') in presence of NaNs 250751931
322894661 https://github.com/pydata/xarray/issues/1509#issuecomment-322894661 https://api.github.com/repos/pydata/xarray/issues/1509 MDEyOklzc3VlQ29tbWVudDMyMjg5NDY2MQ== jhamman 2443309 2017-08-16T20:48:16Z 2017-08-16T20:48:16Z MEMBER

1) I can reproduce this behavior on the current master branch 2) this is consistent with numpy's nansum/nanmean which we use here

```python In [1]: import numpy as np

In [2]: np.sum([np.nan]) Out[2]: nan

In [3]: np.mean([np.nan]) Out[3]: nan

In [4]: np.nansum([np.nan]) Out[4]: 0.0

In [5]: np.nanmean([np.nan]) /glade/u/home/jhamman/anaconda/envs/storylines/bin/ipython:1: RuntimeWarning: Mean of empty slice #!/glade/u/home/jhamman/anaconda/envs/storylines/bin/python Out[5]: nan ```

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Unexpected behavior with DataArray.resample(how='sum') in presence of NaNs 250751931

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