cf.Units.isreftime

Units.isreftime

True if the units are reference time units, false otherwise.

Note that time units are not reference time units and that the existence of the calendar attribute on its own is not sufficient for identifying the presence of reference time units.

Examples

>>> u = Units(units='days since 1989-1-1')
>>> u.isreftime
True
>>> u = Units(units='hours since 2100-1-1', calendar='noleap')
>>> u.isreftime
True
>>> u = Units(units='kg')
>>> u.isreftime
False
>>> u = Units(units='hours')
>>> u.isreftime
False
>>> u = Units(calendar='360_day')
>>> u.isreftime
False

Previous topic

cf.Units.ispressure

Next topic

cf.Units.istime

This Page