Skip to content

Improve naming consistency of methods which convert between UxDataArray, UxDataset, xr.DataArray, and xr.Dataset #1735

Description

@Sevans711

EDIT: the issue title was focused on proposing to implement UxDataArray.to_uxdataset() and UxDataset.to_uxdataarray(), but I later discovered the relevant functionality actually exists, it just wasn't named what I was expecting. See next message for details.

Below was the original text for this message, less relevant now but I am keeping it here for reference:

These should both work in the intuitive way, analogously to xarray.DataArray.to_dataset() and xarray.Dataset.to_dataarray().

These may be especially relevant as an easy-to-implement workaround for #1734 (and could maybe even be used while solving that issue?), as it would enable something like ds.to_uxdataarray('variable').zonal_mean().to_dataset('variable'), and similar for any other currently-only-defined-for-UxDataArray methods.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

designDesign of an API, feature, or user interface (not just implementation details)developer experienceMakes the codebase easier to read, debug, maintain, or extend.

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions