home / github

Menu
  • GraphQL API
  • Search all tables

issue_comments

Table actions
  • GraphQL API for issue_comments

4 rows where issue = 455262061 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

  • dcherian 2
  • huard 1
  • tommylees112 1

author_association 3

  • MEMBER 2
  • CONTRIBUTOR 1
  • NONE 1

issue 1

  • Add quantile method to groupby object · 4 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
507749287 https://github.com/pydata/xarray/issues/3018#issuecomment-507749287 https://api.github.com/repos/pydata/xarray/issues/3018 MDEyOklzc3VlQ29tbWVudDUwNzc0OTI4Nw== dcherian 2448579 2019-07-02T16:23:57Z 2019-07-02T16:23:57Z MEMBER

OK looks like the method was added to the DataArrayGroupBy class not GroupBy. I should've caught this at review. Just moving the function definition to GroupBy seems to make things work

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add quantile method to groupby object 455262061
507743549 https://github.com/pydata/xarray/issues/3018#issuecomment-507743549 https://api.github.com/repos/pydata/xarray/issues/3018 MDEyOklzc3VlQ29tbWVudDUwNzc0MzU0OQ== dcherian 2448579 2019-07-02T16:08:51Z 2019-07-02T16:08:51Z MEMBER

Well that was an oversight. Any interest in opening a PR @tommylees112 or @huard

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add quantile method to groupby object 455262061
507685922 https://github.com/pydata/xarray/issues/3018#issuecomment-507685922 https://api.github.com/repos/pydata/xarray/issues/3018 MDEyOklzc3VlQ29tbWVudDUwNzY4NTkyMg== huard 81219 2019-07-02T13:50:27Z 2019-07-02T13:50:27Z CONTRIBUTOR

The PR only covered DataArrays, not Datasets, so yes, this is expected.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add quantile method to groupby object 455262061
507630032 https://github.com/pydata/xarray/issues/3018#issuecomment-507630032 https://api.github.com/repos/pydata/xarray/issues/3018 MDEyOklzc3VlQ29tbWVudDUwNzYzMDAzMg== tommylees112 21049064 2019-07-02T11:10:33Z 2019-07-02T11:10:33Z NONE

This is an awesome addition thankyou! I updated my xarray to V:0.12.2 but I am still getting an error with dataset objects

```python a = np.ones((400)) * 10 a[3:7] = 0.2 a[10:13] = 0.2 p = np.repeat(a, 25).reshape(400, 5, 5) lat = np.arange(0, 5) lon = np.arange(0, 5) time = pd.date_range('2000-01-01', freq='M', periods=p.shape[0]) d = xr.Dataset( {'precip': (['time', 'lat', 'lon'], p)}, coords={ 'lon': lon, 'lat': lat, 'time': time } )

d.groupby('time.month').quantile(q=0.1) ```

gives the error message ```


AttributeError Traceback (most recent call last) <ipython-input-38-276cfe319286> in <module> ----> 1 d.groupby('time.month').quantile(q=0.1)

AttributeError: 'DatasetGroupBy' object has no attribute 'quantile' ```

Whereas for the DataArray it works fine. ```python d.precip.groupby('time.month').quantile(q=0.1)

Out[39]: <xarray.DataArray 'precip' (month: 12)> array([10., 10., 10., 10., 10., 10., 10., 10., 10., 10., 10., 10.]) Coordinates: * month (month) int64 1 2 3 4 5 6 7 8 9 10 11 12 ```

Is this the expected behaviour?

``` INSTALLED VERSIONS


commit: None python: 3.7.0 | packaged by conda-forge | (default, Nov 12 2018, 12:34:36) [Clang 4.0.1 (tags/RELEASE_401/final)] python-bits: 64 OS: Darwin OS-release: 18.2.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: en_US.UTF-8 LANG: en_US.UTF-8 LOCALE: en_US.UTF-8 libhdf5: 1.10.4 libnetcdf: 4.6.2

xarray: 0.12.2 pandas: 0.24.2 numpy: 1.16.4 scipy: 1.3.0 netCDF4: 1.5.1.2 pydap: None h5netcdf: None h5py: 2.9.0 Nio: None zarr: None cftime: 1.0.3.4 nc_time_axis: None PseudonetCDF: None rasterio: 1.0.17 cfgrib: 0.9.7 iris: None bottleneck: 1.2.1 dask: 1.2.2 distributed: 1.28.1 matplotlib: 3.1.0 cartopy: 0.17.0 seaborn: 0.9.0 numbagg: None setuptools: 41.0.1 pip: 19.1 conda: None pytest: 4.5.0 IPython: 7.1.1 sphinx: 2.0.1 ```

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add quantile method to groupby object 455262061

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