Skip to content

Conversation

@keewis
Copy link
Member

@keewis keewis commented Jul 22, 2021

This exposes the internal use of None as a "no unit" value and adds the new values requested in #118 (I skipped the integer 1 for now but it should be a single line change to add it).

cc @dcherian, @jbusecke

  • Closes units = "none"? #118
  • Tests added
  • Passes pre-commit run --all-files
  • User visible changes (including notable bug fixes) are documented in whats-new.rst
  • New functions/methods are listed in api.rst

@dcherian
Copy link

"none" as "no unit" seems sensible to me. "1" is dimensionless in the CF conventions. Should that be different from "no units"?

@keewis
Copy link
Member Author

keewis commented Jul 22, 2021

"none" as "no unit" seems sensible to me. "1" is dimensionless in the CF conventions. Should that be different from "no units"?

fine with me. Seems like we shouldn't put this in pint-xarray, then?

@keewis keewis requested a review from TomNicholas July 23, 2021 00:15
Copy link
Member

@TomNicholas TomNicholas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @keewis - the only other thing I would add is some kind of example or note in the documentation to show this feature, beyond just the note in the quantify docstring.

Copy link
Member

@TomNicholas TomNicholas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

@keewis
Copy link
Member Author

keewis commented Jul 23, 2021

great, let's merge. I'll try to create a few more PRs with small fixes, merge #110 and then issue a minor release.

@keewis keewis merged commit 0732ea9 into xarray-contrib:master Jul 23, 2021
@keewis keewis deleted the no_unit_values branch July 23, 2021 18:51
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

Successfully merging this pull request may close these issues.

units = "none"?

3 participants