Open jonrkarr opened 3 years ago
- CellML -- could capture units with annotations, but I don't think this is done and certainly sufficiently consistently to read this information with code. Units could be captured in OMEX Metadata files, but no one is doing that.
CellML has units defined as follows:
<units name="uA">
<unit prefix="micro" units="ampere"/>
</units>
which can then be used in variables as
<component name="membrane">
...
<variable name="I_Stim" public_interface="out" units="uA"/>
</component>
Am I missing something regarding why this is different from SBML/ considered not supported?
Not only are CellML units present and supported, they are also required.
Actually, it goes even further than that--CellML interpreters are supposed to at least have the option to have units affect the mathematics. In SBML '1 + 1' will always equal '2' even if they are different units (in which case, you can get a unit validation error/warning.) But in CellML, '1 g + 1 cg' should be allowed to equal 1.01 g. (Though somehow this is optional? I think?)
This information would be useful for composition.
Tagging @eagmon.