Currently we have functions that use name and attributes of unit
def add_custom_unit(self, units_name, unit_attributes):
"""Define a new Pint unit definition and adds it to the unit registry.
:param units_name: name of unit to add - cannot be an existing CellML unit
:param unit_attributes: dict object for unit
{'multiplier': float, 'units': string, 'exponent': integer, 'prefix': string/integer}
Not all fields necessary but 'units' must match a unit in Pint registry
"""
we need to be able to add a Unit object (obtained elsewhere) but this not as straightforward as it might seem.
Currently we have functions that use name and attributes of unit
we need to be able to add a Unit object (obtained elsewhere) but this not as straightforward as it might seem.