home / github / issue_comments

Menu
  • Search all tables
  • GraphQL API

issue_comments: 1523666774

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/6610#issuecomment-1523666774 https://api.github.com/repos/pydata/xarray/issues/6610 1523666774 IC_kwDOAMm_X85a0U9W 2448579 2023-04-26T15:59:06Z 2023-04-26T16:06:17Z MEMBER

We voted to move forward with this API: python data.groupby({ "x0": xr.BinGrouper(bins=pd.IntervalIndex.from_breaks(coords["x_vertices"])), # binning "y": xr.UniqueGrouper(labels=["a", "b", "c"]), # categorical, data.y is dask-backed "time": xr.TimeResampleGrouper(freq="MS") }, )

We won't break backwards-compatibility for da.groupby(other_data_array) but for any complicated use-cases with Grouper the user must add the by variable to the xarray object, and refer to it by name in the dictionary as above,

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