-
-
Notifications
You must be signed in to change notification settings - Fork 25.8k
[MRG] Use defined notation for precision and recall #12726
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
Conversation
Replace undefined "`A`" and "`B`" in definitions of precision, recall, and F-beta with defined symbols "`y_l`" and "`\hat{y}_l`" and correct the resulting definitions.
I missed that the definitions use `\hat{y}` for true labels and `y` for predicted labels, so I had precision and recall reversed.
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.
thanks @gsganden
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.
I disagree, and would like to see this reverted.
Those definitions of P and R are generic functions applied to generic sets. I don't mind them being y
and \hat{y}
but using _l
is in direct contradiction to what is described below in regards to different averaging.
Please do raise issues with respect to other errors in the documentation here.
Replace undefined symbols
A
andB
in the definitions of precision, recall, and F-beta with defined symbolsy_l
and\hat{y}_l
.Reference Issues/PRs
NA
What does this implement/fix? Explain your changes.
The user guide on model evaluation defines precision and recall in terms of
A
andB
without defining those symbols. There does seem to be a convention in the Information Retrieval literature of usingA
refer to relevant document (analogous to positive samples) andB
to refer to retrieved documents (analogous to positive predictions). We already have defined symbols for those concepts, namely\hat{y}_l
andy_l
, respectively, wherel
is the "positive" class label. When I replaceA
with\hat{y}_l
andB
withy_l
, then the resulting definitions of precision and recall are reversed, so I correct that issue in addition to the simple find-and-replace operation.Any other comments?
The more I look at this section of the document, the more apparent problems I find. I think this PR fixes one of them.