code: def test_multiclass_classification():
      iris = load_iris()
      y = iris["target"]
      X = iris["data"]
      kf = KFold(y.shape[0], n_folds=2, shuffle=True, random_state=rng)
      for train_index, test_index in kf:
          xgb_model = xgb.XGBClassifier().fit(
              X[train_index], y[train_index]
          )
          preds = xgb_model.predict(X[test_index])
          # test other params in XGBClassifier().fit
          preds2 = xgb_model.predict(
              X[test_index], output_margin=True, ntree_limit=3
          )
          preds3 = xgb_model.predict(
              X[test_index], output_margin=True, ntree_limit=0
          )
          preds4 = xgb_model.predict(
              X[test_index], output_margin=False, ntree_limit=3
          )
          labels = y[test_index]
          err = sum(
              1
              for i in range(len(preds))
              if int(preds[i] > 0.5) != labels[i]
          ) / float(len(preds))
      assert err < 0.4
  
file_path: turicreate/src/external/xgboost/tests/python/test_with_sklearn.py
imports: import xgboost
  import numpy
  from sklearn.cross_validation import KFold, train_test_split
  from sklearn.metrics import mean_squared_error
  from sklearn.grid_search import GridSearchCV
  from sklearn.datasets import load_iris, load_digits, load_boston
label_desc: Use image node_id 2 for calling a global function with example usage: test_multiclass_classification() without return types