Skip to content

Ensure no missing values in coordinates #190

@rsignell-usgs

Description

@rsignell-usgs

I know this should really be done in xarray, but I've been using the xbitinfo .to_compressed_netcdf() and .to_compressed_zarr() convenience functions even when I'm not using bitrounding because... they are convenient! :)

CF conventions don't allow missing values in coordinates but xarray produces them nonetheless. I usually remove them via this little code snippet:

for index in ds.indexes:
    ds[index].encoding['_FillValue'= None

Would there be any downside to adding this to to_compressed_netcdf so users don't have to?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions