home / github / issue_comments

Menu
  • GraphQL API
  • Search all tables

issue_comments: 325152586

This data as json

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/issues/1527#issuecomment-325152586 https://api.github.com/repos/pydata/xarray/issues/1527 325152586 MDEyOklzc3VlQ29tbWVudDMyNTE1MjU4Ng== 1217238 2017-08-26T18:02:35Z 2017-08-26T18:02:35Z MEMBER

This seems to be related somehow to the fact that 1979 isn't a leap year, so we have a missing value to fill in for 366. For example, it works if we switch to 2004 for d2: ``` In [14]: d2 = xr.DataArray(np.zeros((366, 10)), {'time': pd.date_range('2004-01-01', freq='D', periods=366), 'x': ('x', np.ara ...: nge(10))}, dims=['time', 'x'])

In [15]: d1.groupby('time.dayofyear') - d2.groupby('time.dayofyear').mean('time') Out[15]: <xarray.DataArray (time: 12000, x: 10)> array([[ 0., 0., 0., ..., 0., 0., 0.], [ 0., 0., 0., ..., 0., 0., 0.], [ 0., 0., 0., ..., 0., 0., 0.], ..., [ 0., 0., 0., ..., 0., 0., 0.], [ 0., 0., 0., ..., 0., 0., 0.], [ 0., 0., 0., ..., 0., 0., 0.]]) Coordinates: * x (x) int64 0 1 2 3 4 5 6 7 8 9 * time (time) datetime64[ns] 1979-01-01 1979-01-02 1979-01-03 ... dayofyear (time) int64 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 ... ```

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  253107677
Powered by Datasette · Queries took 1.004ms · About: xarray-datasette