decision_plot
Plot SHAP's decision plot. Visualize model decisions using cumulative SHAP values. Each plotted line explains a single model prediction. If a single prediction is plotted, feature values will be printed in the plot (if supplied). If multiple predictions are plotted together, feature values will not be printed. Plotting too many predictions together will make the plot unintelligible. Read more about SHAP plots in the user guide.
Parameters: |
models: str, sequence or None, optional (default=None)
index: int, tuple, slice or None, optional (default=None)
show: int or None, optional (default=None)
target: int or str, optional (default=1)
title: str or None, optional (default=None)
figsize: tuple or None, optional (default=None)
filename: str or None, optional (default=None)
display: bool or None, optional (default=True)
**kwargs |
Returns: |
fig: matplotlib.figure.Figure Plot object. Only returned if display=None .
|
Example
from atom import ATOMRegressor
atom = ATOMRegressor(X, y)
atom.run("RF")
atom.decision_plot() # For multiple samples
atom.decision_plot(index=120) # For a single sample