Replies: 2 comments
-
|
Thanks for bringing up the discussion! I think |
Beta Was this translation helpful? Give feedback.
-
|
First draft of the units handling is implemented in #239. Right now only Examplefrom mendeleev import H
# without units
H.atomic_radius
25.0
# with units
H.atomic_radius_u
<Quantity(25.0, 'picometer')>
# with unit conversion
H.atomic_radius_u.to("bohr")
<Quantity(0.4724315311555698, 'bohr')>Feedback is most welcome. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Many properties available in
mendeleevnext to numerical values have also units of measurement. The units for most properties are documented in the data page in the docs. All units except for isotope half life are consistent across all value for a given property. This means for example that all boiling points are expressed in Kelvins and covalent radii are in picometers.Thanks to recent changes #156 units are now programmatically available through
mendeleev.models.PropertyMetadataand therefore can be used to introduce an interface where quantities are returned with explicit unit.One popular option for modelling units explicitly would be by incorporating the pint package for handling untis.
Open design questions:
Context
Beta Was this translation helpful? Give feedback.
All reactions