(self, key, value)
| 241 | return self.data_array.sel(key) |
| 242 | |
| 243 | def __setitem__(self, key, value) -> None: |
| 244 | if not utils.is_dict_like(key): |
| 245 | # expand the indexer so we can handle Ellipsis |
| 246 | labels = indexing.expanded_indexer(key, self.data_array.ndim) |
| 247 | key = dict(zip(self.data_array.dims, labels, strict=True)) |
| 248 | |
| 249 | dim_indexers = map_index_queries(self.data_array, key).dim_indexers |
| 250 | self.data_array[dim_indexers] = value |
| 251 | |
| 252 | |
| 253 | # Used as the key corresponding to a DataArray's variable when converting |
nothing calls this directly
no test coverage detected