issues: 112253425
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 |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
112253425 | MDU6SXNzdWUxMTIyNTM0MjU= | 630 | Whether a DataArray is copied when inserted into a Dataset depends on whether coordinates match exactly | 1322974 | open | 0 | 16 | 2015-10-19T23:27:15Z | 2019-01-31T18:40:58Z | CONTRIBUTOR | Consider ``` import numpy as np from xray import * ds = Dataset({"a": DataArray(np.zeros((3, 4)))}) ds["b"] = b = DataArray(np.zeros((3, 4))) b[0, 0] = 1 print(ds["b"][0, 0]) # ==> prints 1 ds = Dataset({"a": DataArray(np.zeros((3, 4)))}) ds["b"] = b = DataArray(np.zeros((3, 3))) # !!! we implicitly fill the last column with nans. b[0, 0] = 1 print(ds["b"][0, 0]) # ==> prints 0 ``` In the first case, the dataset was modified when the dataarray was modified, but not in the second case. |
{ "url": "https://api.github.com/repos/pydata/xarray/issues/630/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
13221727 | issue |