home / github / issues

Menu
  • Search all tables
  • GraphQL API

issues: 589112325

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
589112325 MDU6SXNzdWU1ODkxMTIzMjU= 3902 AttributeError: 'DataArray' object has no attribute 'polyfit' 9200184 closed 0     2 2020-03-27T12:51:34Z 2020-03-27T14:08:50Z 2020-03-27T13:59:05Z CONTRIBUTOR      

I used the below code in jupyterlab with xarray 0.15.1: x = xr.DataArray(np.arange(10), dims=['x'], name='x') a = xr.DataArray(3 + 4 * x, dims=['x'], coords={'x': x}) out = a.polyfit(dim='x', deg=1, full=True) out

But output ERROR:


AttributeError Traceback (most recent call last) <ipython-input-19-25ecb9e3a166> in <module> 1 x = xr.DataArray(np.arange(10), dims=['x'], name='x') 2 a = xr.DataArray(3 + 4 * x, dims=['x'], coords={'x': x}) ----> 3 out = a.polyfit(dim='x', deg=1, full=True) 4 out

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 'polyfit'

What is the meaning of this error?!

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/3902/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
  • 2 rows from issue in issue_comments
Powered by Datasette · Queries took 236.462ms · About: xarray-datasette