evalml.model_understanding.graph_partial_dependence(pipeline, X, feature, class_label=None, grid_resolution=100)[source]

Create an one-way partial dependence plot.

  • pipeline (PipelineBase or subclass) – Fitted pipeline

  • X (ww.DataTable, pd.DataFrame, np.ndarray) – The input data used to generate a grid of values for feature where partial dependence will be calculated at

  • feature (int, string) – The target feature for which to create the partial dependence plot for. If feature is an int, it must be the index of the feature to use. If feature is a string, it must be a valid column name in X.

  • class_label (string, optional) – Name of class to plot for multiclass problems. If None, will plot the partial dependence for each class. This argument does not change behavior for regression or binary classification pipelines. For binary classification, the partial dependence for the positive label will always be displayed. Defaults to None.


pd.DataFrame with averaged predictions for all points in the grid averaged

over all samples of X and the values used to calculate those predictions.

Return type