Balancing recall and precision

I liked very much the video about setting threshold other than 0.5 to balance recall and precision.
Please let me ask a question
This balancing procedure is done AFTER the calculation of parameters (w,b). As I understand, the calculation of parameters (w,b), e.g. by gradient descent, implies the value of threshold equal to 0.5. If so, is it legitimate to try different decision thresholds using the (w,b) calculated preliminary for the threshold=0.5?
I hope I plainly expressed my thought :slight_smile: Will be grateful for the answer.


In the training process or the gradient descent of a logistic regression problem, the threshold plays no role at all. Please review the lecture for it.


There is seldom a good reason to use a threshold other than 0.5.

Thank you for the answer!

Thank you very much for the answer, Raymond.
Let me please ask your opinion - is this picture correct (I mean, the change of recall and precision depending on threshold):

My best regards,

Yes,, and if you draw a vertical line through, let’s say, the big dot for the high precision case, then all small dots on the RHS will be predicted as positive. Since only true positive samples are on the RHS, it’s indeed a 100% precision threshold.