home / github / issues

Menu
  • GraphQL API
  • Search all tables

issues: 588928468

This data as json

id node_id number title user state locked assignee milestone comments created_at updated_at closed_at author_association active_lock_reason draft pull_request body reactions performed_via_github_app state_reason repo type
588928468 MDU6SXNzdWU1ODg5Mjg0Njg= 3901 AttributeError: 'DataArray' object has no attribute 'weighted' 9200184 closed 0     4 2020-03-27T06:58:09Z 2020-03-27T10:17:13Z 2020-03-27T10:17:13Z CONTRIBUTOR      

I am learning xarray based on pydata's Doc. In Computation section and "Weighted array reductions" sub-section, when I run: weighted_prec = prec.weighted(weights) weighted_prec

Jupyter came back to me below ERROR:


AttributeError Traceback (most recent call last) <ipython-input-49-3893583b4b62> in <module> 1 import pandas as pd 2 import numpy as np ----> 3 data.weighted(weights).mean()

C:\ProgramData\Anaconda3\lib\site-packages\xarray\core\common.py in getattr(self, name) 231 return source[name] 232 raise AttributeError( --> 233 "{!r} object has no attribute {!r}".format(type(self).name, name) 234 ) 235

AttributeError: 'DataArray' object has no attribute 'weighted'

What is my problem?

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/3901/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  completed 13221727 issue

Links from other tables

  • 0 rows from issues_id in issues_labels
  • 4 rows from issue in issue_comments
Powered by Datasette · Queries took 1.173ms · About: xarray-datasette