code: def test_stacking_classification():
      from sklearn.datasets import load_iris
      from sklearn.ensemble import StackingClassifier
      from sklearn.linear_model import LogisticRegression
      from sklearn.model_selection import train_test_split
      from sklearn.pipeline import make_pipeline
      from sklearn.preprocessing import StandardScaler
      from sklearn.svm import LinearSVC
  
      X, y = load_iris(return_X_y=True)
      estimators = [
          ("gbm", xgb.sklearn.XGBClassifier()),
          (
              "svr",
              make_pipeline(
                  StandardScaler(), LinearSVC(random_state=42)
              ),
          ),
      ]
      clf = StackingClassifier(
          estimators=estimators, final_estimator=LogisticRegression()
      )
  
      X_train, X_test, y_train, y_test = train_test_split(
          X, y, random_state=42
      )
      clf.fit(X_train, y_train).score(X_test, y_test)
  
imports: import json
  import os
  import pickle
  import random
  import tempfile
  import warnings
  from typing import Callable, Optional
  import numpy
  import pytest
  from sklearn.utils.estimator_checks import parametrize_with_checks
  import xgboost
  from xgboost import testing
  from xgboost.testing.ranking import run_ranking_categorical, run_ranking_qid_df
  from xgboost.testing.shared import get_feature_weights, validate_data_initialization
  from xgboost.testing.updater import get_basescore
label_desc: Use image node_id 9 for calling a global function with example usage: test_stacking_classification() without return types