You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When running the example code for the "univariate linear regression", I'm encountering an error that prevents me from generating the plot. I've exported my environment, and am happy to share more details.
exported environment: cfr_env.yaml.zip
The specific error I'm seeing is:
When running the example code for the "univariate linear regression", I'm encountering an error that prevents me from generating the plot. I've exported my environment, and am happy to share more details.
exported environment: cfr_env.yaml.zip
The specific error I'm seeing is:
AttributeError Traceback (most recent call last)
Cell In[13], line 1
----> 1 fig, ax = obs_tas_new.plot(levels=np.linspace(-40, 40, 11))
File ~/anaconda3/envs/cfr-env/lib/python3.11/site-packages/cfr/climate.py:568, in ClimateField.plot(self, **kwargs)
565 _kwargs.update(kwargs)
567 if len(fd_plot.da.dims) == 3:
--> 568 vals = fd_plot.da.values[0]
569 elif len(fd_plot.da.dims) == 2:
570 vals = fd_plot.da.values
File ~/anaconda3/envs/cfr-env/lib/python3.11/site-packages/xarray/core/common.py:302, in AttrAccessMixin.getattr(self, name)
300 with suppress(KeyError):
301 return source[name]
--> 302 raise AttributeError(
303 f"{type(self).name!r} object has no attribute {name!r}"
304 )
AttributeError: 'DataArray' object has no attribute 'values'
The text was updated successfully, but these errors were encountered: