-
Notifications
You must be signed in to change notification settings - Fork 53
Support different inputs for ROC #221
Support different inputs for ROC #221
Conversation
Pull Request Test Coverage Report for Build 3951368466Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
@edublancas @idomic I think it's not the best example for ROC since the accuracy is almost 100% and the curves are "too good" |
…into 98_support_different_inputs_for_roc
…com/yafimvo/sklearn-evaluation into 98_support_different_inputs_for_roc
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good, just rebase on main and let's merge this.
Use the predicted labels or classes to plot an ROC curve. | ||
We support 3 main formats that allow you to quickly generate a single or a multi classification ROC curve. | ||
|
||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's move this to the docstring. and clarify that the first two formats are for the y_true argument and the second format is for y_score
For this example we will plot a multi classification ROC using the predicted classes | ||
|
||
```{code-cell} ipython3 | ||
plot.roc(y_test, y_pred_dt) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there's an error here, y_pred_dt is created with y_pred_dt = dt_model.predict(X_test)
but it should be y_pred_dt = dt_model.predict_proba(X_test)
note that some plots like confusion matrix need the output of predict
, and others like roc need predict_proba
found a minor issue |
@edublancas @idomic |
Describe your changes
Added support for 3 different inputs for ROC curve: lables/classes array, onehot encoded array, and array of values.
Issue ticket number and link
Closes #98
Checklist before requesting a review
📚 Documentation preview 📚: https://sklearn-evaluation--221.org.readthedocs.build/en/221/