Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Name of xarray object should be name of intake object #15

Open
jsignell opened this issue Sep 5, 2018 · 3 comments
Open

Name of xarray object should be name of intake object #15

jsignell opened this issue Sep 5, 2018 · 3 comments

Comments

@jsignell
Copy link
Member

jsignell commented Sep 5, 2018

Outputting named xarray.DataArrays would make it easier to convert to xarray.Datasets and plot.

This should be very straightforward and large reward.

@martindurant
Copy link
Member

Where would the name come from? This applies only to rasterIO or also elsewhere?

@jsignell
Copy link
Member Author

jsignell commented Sep 5, 2018

Where would the name come from?

The name is the key in the catalog. It is already an attribute on the intake object. For example:

>>>cat.us_crime.name
'us_crime'

This applies only to rasterIO or also elsewhere?

I think it should apply everywhere, maybe in other plugins as well, but I haven't explored thoroughly. The pandas analogy for an xr.DataArray is a pd.Series which can also have a name. Naming these things just makes it easier to go to the next order object (xr.Dataset or pd.DataFrame)

@martindurant
Copy link
Member

I see, that makes sense.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants