How do you choose a decision threshold for logistic regression, and why is the default 0.5 often arbitrary?

Quick Overview

Asks how to pick the probability cutoff that turns a logistic regression score into a decision, and why the default of 0.5 often fits poorly. Tests reasoning about error costs, class imbalance, calibration, precision and recall targets, and validation hygiene.

How do you choose a decision threshold for logistic regression, and why is the default 0.5 often arbitrary?

Role: Data Scientist

Category: Machine Learning

Difficulty: medium

Interview Round: Other

How do you select an appropriate decision threshold for a logistic regression model, and why is the default `0.5` often arbitrary? ```hint Price each kind of mistake For one example with predicted probability p, write the expected cost of labeling it positive and the expected cost of labeling it negative. Where are the two equal? ``` ```hint Check what the probabilities mean Ask whether the model's probabilities can be taken at face value, how the training data could have shifted them, and which data split should decide the threshold. ``` ### What a Strong Answer Covers - What the threshold controls and which assumption makes 0.5 the right cutoff. - At least one principled way to select it, such as expected cost, a target precision or recall, or an operational capacity limit. - The role of calibration, and how class weights or resampling shift the predicted probabilities. - Choosing the threshold on validation data and keeping it valid after deployment. ### Follow-up Questions - You trained on a downsampled dataset with 50% positives. How does that affect the threshold you use in production? - How would you choose a threshold when the cost of a false negative is hard to put in dollars? - The fraud base rate doubles a month after launch. What happens to precision at your chosen threshold, and what would you do? - When would you use more than one threshold, or no threshold at all?

Overview: Asks how to pick the probability cutoff that turns a logistic regression score into a decision, and why the default of 0.5 often fits poorly. Tests reasoning about error costs, class imbalance, calibration, precision and recall targets, and validation hygiene.

General logo
General
Nov 25, 2026
mediumData ScientistOtherMachine Learning
0
0

How do you select an appropriate decision threshold for a logistic regression model, and why is the default 0.5 often arbitrary?

What a Strong Answer Covers Guidance

  • What the threshold controls and which assumption makes 0.5 the right cutoff.
  • At least one principled way to select it, such as expected cost, a target precision or recall, or an operational capacity limit.
  • The role of calibration, and how class weights or resampling shift the predicted probabilities.
  • Choosing the threshold on validation data and keeping it valid after deployment.

Follow-up Questions Guidance

  • You trained on a downsampled dataset with 50% positives. How does that affect the threshold you use in production?
  • How would you choose a threshold when the cost of a false negative is hard to put in dollars?
  • The fraud base rate doubles a month after launch. What happens to precision at your chosen threshold, and what would you do?
  • When would you use more than one threshold, or no threshold at all?