Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
edublancas committed Feb 28, 2024
1 parent e0e5773 commit 96456ee
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/sklearn_evaluation/plot/precision_recall.py
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ def plot(self, ax=None):
# User passes list of list for binary
r = r[0] if isinstance(r[0], (list, np.ndarray)) else r
p = p[0] if isinstance(p[0], (list, np.ndarray)) else p
label = f"{l}, AUC={auc(r,p):.2f}"
label = f"{l}, AUC={auc(r, p):.2f}"
ax = _plot_metrics_binary(p, r, label, ax)

_set_ax_settings(ax, "Precision Recall compare")
Expand Down
2 changes: 1 addition & 1 deletion src/sklearn_evaluation/plot/regression.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ def prediction_error(y_true, y_pred, ax=None):

# R2
r2 = model.score(y_reshaped, y_pred)
plt.plot([], [], " ", label=f"R2 = {round(r2,5)}")
plt.plot([], [], " ", label=f"R2 = {round(r2, 5)}")

_set_ax_settings(ax, "y_true", "y_pred", "Prediction Error")
ax.legend(loc="upper left")
Expand Down

0 comments on commit 96456ee

Please sign in to comment.