Stop Using 0.5 as the Threshold for Your Binary Classifier
To produce a binary response, classifiers output a real-valued score that is thresholded. For example, logistic regression outputs a probability (a value between 0.0 and 1.0); and observations with a score equal to or higher than 0.5 produce a positive binary output (many other models use the 0.5 threshold by default). However, using the default 0.5 threshold is suboptimal. In this blog post, I'll show you how you can choose the best threshold from your binary classifier. We'll be using Ploomber to execute our experiments in parallel and sklearn-evaluation to generate the plots.
Nov-29-2022, 19:56:11 GMT
- Technology: