code: def value(self, units=None):
          
          if units is None:
              return self._value
  
          if not units.upper() in CustomPressure.legal_units:
              raise UnitsError("unrecognized pressure unit: '" + units + "'")
          units = units.upper()
          if units == self._units:
              return self._value
          if self._units == "IN":
              mb_value = self._value * 33.86398
          elif self._units == "MM":
              mb_value = self._value * 1.3332239
          else:
              mb_value = self._value
          if units in ("MB", "HPA"):
              return mb_value
          if units == "IN":
              return mb_value / 33.86398
          if units == "MM":
              return mb_value / 1.3332239
  
          raise UnitsError("unrecognized pressure unit: '" + units + "'")
docs: Return the pressure in the specified units.