code: def plot_feature_proportions_against_thresholds(
      feature_proportions, thresholds, ax=None
  ):
      if ax is None:
          _, ax = plt.subplots(1, 1)
      (
          passed_features,
          failed_features,
      ) = partition_into_passed_and_failed_features(
          feature_proportions, thresholds
      )
  
      ax.bar(
          thresholds.keys(),
          [x * 100 for x in thresholds.values()],
          width=0.01,
          color="black",
          alpha=0.5,
      )
      ax.scatter(
          passed_features.keys(),
          [x * 100 for x in passed_features.values()],
          c="g",
      )
      ax.scatter(
          failed_features.keys(),
          [x * 100 for x in failed_features.values()],
          c="r",
      )
      ax.set_title("Feature Importance Compared to Threshold")
      ax.set_xlabel("Feature")
      ax.set_ylabel("% Splits")
      return ax
  
file_path: imodels/imodels/experimental/bartpy/diagnostics/features.py
imports: from collections import Counter
  from typing import List, Mapping, Union, Optional
  import numpy
  import pandas
  import seaborn
  from matplotlib import pyplot
  from ..runner import run_models
  from ..sklearnmodel import SklearnModel
label_desc: Use image node_id 10 for calling a global function with example usage: plot_feature_proportions_against_thresholds(feature_proportions, thresholds, ax) and returns: ax