code: def pubdev_5023_rm_metalearner():
      # Import a sample binary outcome dataset into H2O
      data = h2o.import_file(
          pyunit_utils.locate("smalldata/higgs/higgs_train_10k.csv")
      )
  
      # Identify predictors and response
      x = data.columns
      y = "response"
      x.remove(y)
  
      # For binary classification, response should be a factor
      data[y] = data[y].asfactor()
      gbm_h2o = H2OGradientBoostingEstimator(
          learn_rate=0.1, max_depth=4
      )
      gbm_h2o.train(x=x, y=y, training_frame=data)
  
      try:  # try to access metalearner method for GBM should encounter exception
          print(type(gbm_h2o.metalearner()))
          exit(1)  # should have failed the test
      except Exception as ex:
          print(ex)
  
label_desc: Use image node_id 1 for calling a global function with example usage: pubdev_5023_rm_metalearner() without return types