What is the range of the probability output p in logistic regression?

Quick Overview

Asks what values the predicted probability of a logistic regression model can take and why. Tests understanding of the sigmoid link, the log-odds scale, thresholding into class labels, and what happens to the outputs on separable data or in floating point.

What is the range of the probability output p in logistic regression?

Role: Data Scientist

Category: Machine Learning

Difficulty: easy

Interview Round: Other

What is the range of the probability output `p` in logistic regression? Explain why it has that range and whether the endpoints can be reached. ```hint Check the limits Write out the function that maps the linear score to `p`, then look at its value as the score grows very large or very negative. ``` ### What a Strong Answer Covers - The range of `p`, including whether the endpoints are attainable - The function that produces `p` and why it bounds the output - How `p` relates to the odds and log-odds scales - How `p` becomes a class label and what should set the cutoff - A practical consequence, such as perfect separation or floating-point saturation ### Follow-up Questions - On perfectly separable training data, what happens to the weights and the predicted probabilities during fitting? - Why can a computed `p` come out as exactly 1.0, and how do libraries keep the log loss finite? - If you train with class weights to handle imbalance, can you still read `p` as a probability? - How would you choose a threshold other than 0.5?

Overview: Asks what values the predicted probability of a logistic regression model can take and why. Tests understanding of the sigmoid link, the log-odds scale, thresholding into class labels, and what happens to the outputs on separable data or in floating point.

PracHub logo
General
Nov 25, 2026
easyData ScientistOtherMachine Learning
0
0

What is the range of the probability output p in logistic regression? Explain why it has that range and whether the endpoints can be reached.

What a Strong Answer Covers Guidance

  • The range of p , including whether the endpoints are attainable
  • The function that produces p and why it bounds the output
  • How p relates to the odds and log-odds scales
  • How p becomes a class label and what should set the cutoff
  • A practical consequence, such as perfect separation or floating-point saturation

Follow-up Questions Guidance

  • On perfectly separable training data, what happens to the weights and the predicted probabilities during fitting?
  • Why can a computed p come out as exactly 1.0, and how do libraries keep the log loss finite?
  • If you train with class weights to handle imbalance, can you still read p as a probability?
  • How would you choose a threshold other than 0.5?