code: def _plot_pca_classification(
      n_components,
      features_imp,
      target,
      *,
      scatter_alpha="auto",
      scatter_size="auto",
      random_state=None,
  ):
      pca = PCA(n_components=n_components)
      features_scaled = scale(features_imp)
      features_pca = pca.fit_transform(features_scaled)
      feature_names = ["PCA {}".format(i) for i in range(n_components)]
      fig, axes = _plot_top_pairs(
          features_pca,
          target,
          scatter_alpha=scatter_alpha,
          scatter_size=scatter_size,
          feature_names=feature_names,
          how_many=3,
          additional_axes=1,
          random_state=random_state,
      )
      ax = axes.ravel()[-1]
      ax.plot(pca.explained_variance_ratio_, label="variance")
      ax.plot(
          np.cumsum(pca.explained_variance_ratio_),
          label="cumulative variance",
      )
      ax.set_title("Scree plot (PCA explained variance)")
      ax.legend()
      fig.suptitle("Discriminating PCA directions")
      return features_scaled
  
imports: import warnings
  import numpy
  import matplotlib.pyplot
  import matplotlib
  import seaborn
  import pandas
  from sklearn.feature_selection import mutual_info_regression, mutual_info_classif, f_classif
  from sklearn.impute import SimpleImputer
  from sklearn.preprocessing import scale
  from sklearn.decomposition import PCA
  from sklearn.discriminant_analysis import LinearDiscriminantAnalysis
  from sklearn.metrics import recall_score
  from ..preprocessing import detect_types, clean
  from .utils import _check_X_target_col, _get_n_top, _make_subplots, _short_tick_names, _shortname, _prune_category_make_X, find_pretty_grid, _find_scatter_plots_classification, class_hists, discrete_scatter, mosaic_plot, _find_inliers, pairplot, _get_scatter_alpha, _get_scatter_size, _find_categorical_for_regression, _prune_categories, _apply_eng_formatter
  from .sankey import plot_sankey
  from warnings import warn
label_desc: Use image node_id 4 for calling a global function with example usage: _plot_pca_classification(n_components, features_imp, target) and returns: features_scaled