8000 [MRG] BUG Adds space to error message in plot_roc_curve by thomasjpfan · Pull Request #14597 · scikit-learn/scikit-learn · GitHub
[go: up one dir, main page]

Skip to content

[MRG] BUG Adds space to error message in plot_roc_curve #14597

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension
8000
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions doc/whats_new/v0.22.rst
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,10 @@ Changelog
:mod:`sklearn.metrics`
......................

- |MajorFeature| :func:`metrics.plot_roc_curve` has been added to plot roc
curves. This function introduces the visualization API described in
the :ref:`User Guide <visualizations>`. :pr:`14357` by `Thomas Fan`_.

- |Feature| Added multiclass support to :func:`metrics.roc_auc_score`.
:issue:`12789` by :user:`Kathy Chen <kathyxchen>`,
:user:`Mohamed Maskani <maskani-moh>`, and :user:`Thomas Fan <thomasjpfan>`.
Expand Down
2 changes: 1 addition & 1 deletion sklearn/metrics/_plot/roc_curve.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ def plot_roc_curve(estimator, X, y, pos_label=None, sample_weight=None,

if y_pred.ndim != 1:
if y_pred.shape[1] > 2:
raise ValueError("Estimator should solve a"
raise ValueError("Estimator should solve a "
"binary classification problem")
y_pred = y_pred[:, 1]
fpr, tpr, _ = roc_curve(y, y_pred, pos_label=pos_label,
Expand Down
0