code: def _delegate_to_metrics(
      self, method, train=False, valid=False, xval=False, **kwargs
  ):
      tm = ModelBase._get_metrics(self, train, valid, xval)
      m = {}
      for k, v in tm.items():
          if v is None:
              m[k] = None
          elif hasattr(v, method) and callable(getattr(v, method)):
              m[k] = getattr(v, method)(**kwargs)
          else:
              raise ValueError(
                  "no method {} in {}".format(method, type(v))
              )
      return list(m.values())[0] if len(m) == 1 else m
  
imports: from h2o.utils.compatibility import *
  from h2o.exceptions import H2OValueError
  from h2o.model import ModelBase
  from h2o.model.extensions import has_extension
  from h2o.utils.metaclass import deprecated_params
  from h2o.utils.typechecks import assert_is_type
label_desc: Use image node_id 29 for calling the H2OBinomialModel obj's underlying member method code with example usage: obj._delegate_to_metrics(method, train, valid, xval) and returns: unknown