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

Cannot slice and then convert variables #27

Open
jbisits opened this issue Jan 16, 2023 · 1 comment
Open

Cannot slice and then convert variables #27

jbisits opened this issue Jan 16, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@jbisits
Copy link
Owner

jbisits commented Jan 16, 2023

Choosing a slice of the data generates a Raster but is has dims and refdims. Need to address this to be able to select a slice and then apply the conversion/computation functions.

@jbisits
Copy link
Owner Author

jbisits commented Jan 16, 2023

One idea is to check if a raster has a refdims using isempty(refdims(raster)) and if this is not true rebuild the raster with the refdims and dims, e.g.,

Raster(raster, (refdims(raster)..., dims(raster)...))

If doing this also need to sortdims so that they match the raster for the other functions that use the raster to create a blank Array to populate. Another option could be to use setdims.

@jbisits jbisits added the bug Something isn't working label Apr 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant