code: def is_missing(data, missing_value):
      
      if is_float(data) and isnan(missing_value):
          return isnan(data)
      elif is_datetime(data) and isnat(missing_value):
          return isnat(data)
      return (data == missing_value)
docs: Generic is_missing function that handles NaN and NaT.