home / github / issue_comments

Menu
  • Search all tables
  • GraphQL API

issue_comments: 482719668

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/422#issuecomment-482719668 https://api.github.com/repos/pydata/xarray/issues/422 482719668 MDEyOklzc3VlQ29tbWVudDQ4MjcxOTY2OA== 14314623 2019-04-12T20:54:23Z 2019-04-12T20:54:23Z CONTRIBUTOR

I have to say that I am still pretty bad at thinking fully object orientented, but is this what we want in general? A subclass of xr.DataArray which gets initialized with a weight array and with some logic for nans then 'knows' about the weight count? Where would I find a good analogue for this sort of organization? In the rolling class?

I like the syntax proposed by @jhamman above, but I am wondering what happens in a slightly modified example: ```

da.shape (72, 10, 15) da.dims ('time', 'x', 'y') weights = some_func_of_x(x) da.weighted(weights).mean(dim=('x', 'y')) `` I think we should maybe build in a warning that when theweights` array does not contain both of the average dimensions?

It was mentioned that the functions on ...weighted(), would have to be mostly rewritten since the logic for a weigthed average and std differs. What other functions should be included (if any)?

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