issue_comments
16 rows where author_association = "MEMBER" and issue = 307783090 sorted by updated_at descending
This data as json, CSV (advanced)
Suggested facets: reactions, created_at (date), updated_at (date)
issue 1
- rolling: allow control over padding · 16 ✖
id | html_url | issue_url | node_id | user | created_at | updated_at ▲ | author_association | body | reactions | performed_via_github_app | issue |
---|---|---|---|---|---|---|---|---|---|---|---|
876579830 | https://github.com/pydata/xarray/issues/2007#issuecomment-876579830 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDg3NjU3OTgzMA== | dcherian 2448579 | 2021-07-08T16:30:06Z | 2021-07-08T16:30:06Z | MEMBER | Yes. I think we might want this anyway; for |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
875980218 | https://github.com/pydata/xarray/issues/2007#issuecomment-875980218 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDg3NTk4MDIxOA== | dcherian 2448579 | 2021-07-07T22:38:08Z | 2021-07-07T22:38:08Z | MEMBER | This should be easy now so we just need someone to try it out. This is where the padding happens so the kwarg needs to be passed all the way down to What should the API be? |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
747376047 | https://github.com/pydata/xarray/issues/2007#issuecomment-747376047 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDc0NzM3NjA0Nw== | mathause 10194086 | 2020-12-17T11:14:33Z | 2020-12-17T16:02:25Z | MEMBER | I just need to find the three warmest consecutive months from a temperature dataset for my work, so I thought I add a complete example. First, create an example dataset with monthly temperature: ```python import xarray as xr import numpy as np import pandas as pd time = pd.date_range("2000", periods=12 * 30, freq="M") temp = np.sin((time.month - 5) / 6 * np.pi) + np.random.randn(*time.shape) * 0.3 da = xr.DataArray(temp, dims=["time"], coords=dict(time=time)) print(da) ```
Currently we can achieve this like: ```python n_months = 3 monthly = da.groupby("time.month").mean() padded = monthly.pad(month=n_months, mode="wrap") rolled = padded.rolling(center=True, month=n_months).mean(skipna=False) sliced = rolled.isel(month=slice(3, -3)) central_month = sliced.idxmax() ``` Implementing ```python monthly = da.groupby("time.month").mean() rolled = monthly.rolling(center=True, month=n_months, pad_mode="wrap").mean(skipna=False) central_month = rolled.idxmax() ``` |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
747500929 | https://github.com/pydata/xarray/issues/2007#issuecomment-747500929 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDc0NzUwMDkyOQ== | dcherian 2448579 | 2020-12-17T15:16:06Z | 2020-12-17T15:16:06Z | MEMBER | I think we should do |
{ "total_count": 1, "+1": 1, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
499603340 | https://github.com/pydata/xarray/issues/2007#issuecomment-499603340 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDQ5OTYwMzM0MA== | shoyer 1217238 | 2019-06-06T18:01:54Z | 2019-06-06T18:01:54Z | MEMBER | I think you may need to do cropping afterwards, too, before taking the mean. |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
499548285 | https://github.com/pydata/xarray/issues/2007#issuecomment-499548285 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDQ5OTU0ODI4NQ== | mathause 10194086 | 2019-06-06T15:36:58Z | 2019-06-06T15:36:58Z | MEMBER | I am coming back to @shoyer suggestion in #2011 - your idea would be to do first a ``` python import numpy as np import xarray as xr x = np.arange(1, 366) y = np.random.randn(365) ds = xr.DataArray(y, dims=dict(dayofyear=x)) ds.pad(dayofyear=15, mode='wrap').rolling(center=True, dayofyear=31).mean() ``` |
{ "total_count": 1, "+1": 1, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
375850170 | https://github.com/pydata/xarray/issues/2007#issuecomment-375850170 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDM3NTg1MDE3MA== | max-sixty 5635139 | 2018-03-24T06:16:29Z | 2018-03-24T06:16:29Z | MEMBER | 2011 looks good - I didn't realize numpy already had
|
{ "total_count": 1, "+1": 1, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
375828864 | https://github.com/pydata/xarray/issues/2007#issuecomment-375828864 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDM3NTgyODg2NA== | fujiisoup 6815844 | 2018-03-24T00:05:08Z | 2018-03-24T00:05:08Z | MEMBER |
Agreed.
Only a slight modification of |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
375810316 | https://github.com/pydata/xarray/issues/2007#issuecomment-375810316 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDM3NTgxMDMxNg== | max-sixty 5635139 | 2018-03-23T22:03:24Z | 2018-03-23T22:03:24Z | MEMBER | @fujiisoup Yes for sure - I think it would be good. I think there are two salient questions:
- Where this lives in the API: Should this be under |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
375681041 | https://github.com/pydata/xarray/issues/2007#issuecomment-375681041 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDM3NTY4MTA0MQ== | fujiisoup 6815844 | 2018-03-23T14:22:57Z | 2018-03-23T14:22:57Z | MEMBER | @maxim-lian , do you agree to add this feature?
Although the same behavior can be realized by adding head/tail values to the original array and truncate them after the computation, the |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
375484121 | https://github.com/pydata/xarray/issues/2007#issuecomment-375484121 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDM3NTQ4NDEyMQ== | max-sixty 5635139 | 2018-03-22T22:56:09Z | 2018-03-22T22:56:09Z | MEMBER | Though I'm not sure you need the IIUC you need to copy a window-sized amount of data from the front of the array onto the back. You could do that with construct-like machinery, which would save a copy - though not a large copy |
{ "total_count": 1, "+1": 1, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
375476906 | https://github.com/pydata/xarray/issues/2007#issuecomment-375476906 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDM3NTQ3NjkwNg== | fujiisoup 6815844 | 2018-03-22T22:22:26Z | 2018-03-22T22:22:26Z | MEMBER | I think the implementation would be not so difficult by supporting more flexible Maybe @mathause, any interest in contributing? |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
375455202 | https://github.com/pydata/xarray/issues/2007#issuecomment-375455202 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDM3NTQ1NTIwMg== | mathause 10194086 | 2018-03-22T20:57:59Z | 2018-03-22T20:57:59Z | MEMBER | I think what I want is like the I found two possibilities but they are quite "hand made" and certainly not very efficient Solution with slicing: ``` python take the last and first elements and append/ prepend themfirst = ds[:15] last = ds[-15:] extended = xr.concat([last, ds, first], 'dayofyear') do the rolling on the extended ds and get rid of NaNssol1 = extended.rolling(dayofyear=31, center=True).mean().dropna('dayofyear') ``` Solution with |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
375445915 | https://github.com/pydata/xarray/issues/2007#issuecomment-375445915 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDM3NTQ0NTkxNQ== | mathause 10194086 | 2018-03-22T20:26:24Z | 2018-03-22T20:27:59Z | MEMBER | Probably a mix of both - I want to compute a moving average, but with periodic boundaries.
and so on... |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
375441040 | https://github.com/pydata/xarray/issues/2007#issuecomment-375441040 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDM3NTQ0MTA0MA== | max-sixty 5635139 | 2018-03-22T20:09:54Z | 2018-03-22T20:09:54Z | MEMBER |
What do you mean by Specifically, what's the |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 | |
375431424 | https://github.com/pydata/xarray/issues/2007#issuecomment-375431424 | https://api.github.com/repos/pydata/xarray/issues/2007 | MDEyOklzc3VlQ29tbWVudDM3NTQzMTQyNA== | rabernat 1197350 | 2018-03-22T19:35:50Z | 2018-03-22T19:35:50Z | MEMBER | Very useful suggestion.
We already support a different type of "rolling" with periodicity http://xarray.pydata.org/en/latest/generated/xarray.DataArray.roll.html?highlight=roll and it is straightforward to apply roll operations at the variable level: https://github.com/pydata/xarray/blob/master/xarray/core/variable.py#L1007-L1026 I suspect this would not be too hard to implement. |
{ "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
rolling: allow control over padding 307783090 |
Advanced export
JSON shape: default, array, newline-delimited, object
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]);
user 6