Opening your learning space
Starting the app …
Opening your learning space
Starting the app …
Logistic regression maps a linear score to a Bernoulli probability and estimates coefficients by maximizing likelihood or minimizing negative log-likelihood.
Free to browse · flashcards or a multiple-choice quiz · import from Essential
Formula
p and labels are dimensionless; negative log-likelihood is in nats with natural logarithms
| Symbol | Meaning | Unit |
|---|---|---|
| Bernoulli label, zero or one | feature values | |
| Predicted probability of label one | scale-dependent | |
| Linear score | dimensionless | |
| Coefficient vector | 0 or 1 | |
| Negative log-likelihood | nats when using ln |
p_i=\sigma(w^Tx_i+b),\quad -\ell= -\sum_i[y_i\log p_i+(1-y_i)\log(1-p_i)]For independent binary observations, pi=σ(wᵀxi+b) and log-likelihood is Σ[yi ln pi+(1−yi)ln(1−pi)]. The sigmoid-only transform is not the estimation objective; maximum likelihood chooses parameters from data. Complete separation can make unregularized estimates diverge, while regularization changes the fit. Probabilities depend on model specification and calibration; a threshold is needed for hard labels.
For independent binary observations, pi=σ(wᵀxi+b) and log-likelihood is Σ[yi ln pi+(1−yi)ln(1−pi)]. The sigmoid-only transform is not the estimation objective; maximum likelihood chooses parameters from data. Complete separation can make unregularized estimates diverge, while regularization changes the fit. Probabilities depend on model specification and calibration; a threshold is needed for hard labels.
Logistic regression maps a linear score to a Bernoulli probability and estimates coefficients by maximizing likelihood or minimizing negative log-likelihood.
Defining relation
The equation states the defining relation within its stated domain.
Use the example for Logistic regression as a Bernoulli likelihood to explain which inputs determine the requested output.
The example connects concrete inputs to its result.
Logistic regression maps a linear score to a Bernoulli probability and estimates coefficients by maximizing likelihood or minimizing negative log-likelihood.
The relation applies only under its stated assumptions.
Applying the relation to a different case without checking its stated assumptions.
Check the validity range before substituting values: For independent binary observations, pi=σ(wᵀxi+b) and log-likelihood is Σ[yi ln pi+(1−yi)ln(1−pi)]. The sigmoid-only transform is not the estimation objective; maximum likelihood chooses parameters from data. Complete separation can make unregularized.
Formula cluster
Logistic regression maps a linear score to a Bernoulli probability and estimates coefficients by maximizing likelihood or minimizing negative log-likelihood.
For two observations with scores −ln 3 and +ln 3 and labels 0 and 1, correct-class probabilities are 0.75 each. Likelihood is 0.752=0.5625 and negative log-likelihood is −ln(0.5625)≈0.5754 nats. This is distinct from the zero-one classification error.
Estimate binary event probabilities and interpret the Bernoulli training objective.
Here is how to work through a typical Logistic regression as a Bernoulli likelihood (Bernoulli negative log-likelihood) task step by step:
Task
Use the example for Logistic regression as a Bernoulli likelihood to explain which inputs determine the requested output.
Solution path
The example connects concrete inputs to its result.
Logistic regression maps a linear score to a Bernoulli probability and estimates coefficients by maximizing likelihood or minimizing negative log-likelihood.
The relation applies only under its stated assumptions.
The relation pi=\sigma(w^Tx_i+b),\quad -\ell= -\sum_i[yi\log pi+(1-yi)\log(1-pi)] summarizes Logistic regression maps a linear score to a Bernoulli probability and estimates coefficients by maximizing likelihood or minimizing negative log-likelihood. Read it as a model for defined quantities, not as an automatic claim about every real situation. In the example For two observations with scores −ln 3 and +ln 3 and labels 0 and 1, correct-class probabilities are 0.75 each. Likelihood is 0.752=0.5625 and negative log-likelihood is −ln(0.5625)≈0.5754 nats. This is distinct from the zero-one classification error., symbols are connected to concrete values and the result is interpreted in context. Validity limit: For independent binary observations, pi=σ(wᵀxi+b) and log-likelihood is Σ[yi ln pi+(1−yi)ln(1−pi)]. The sigmoid-only transform is not the estimation objective; maximum likelihood chooses parameters from data. Complete separation can make unregularized Source: scikit-learn User Guide, §1.1 Linear Models: Logistic regression and log loss.
First write down the requested quantity and all given values with their symbols. Substitute them into the defining relation and check unit consistency. The example For two observations with scores −ln 3 and +ln 3 and labels 0 and 1, correct-class probabilities are 0.75 each. Likelihood is 0.752=0.5625 and negative log-likelihood is −ln(0.5625)≈0.5754 nats. This is distinct from the zero-one classification error. provides a worked check: formula and result must have compatible scale and meaning; round only at the end. Validity limit: For independent binary observations, pi=σ(wᵀxi+b) and log-likelihood is Σ[yi ln pi+(1−yi)ln(1−pi)]. The sigmoid-only transform is not the estimation objective; maximum likelihood chooses parameters from data. Complete separation can make unregularized Source: scikit-learn User Guide, §1.1 Linear Models: Logistic regression and log loss.
The formula applies only when quantities are defined as in the source and background. Check boundary cases, measurement conditions and whether an approximation rather than equality is intended. Substitution can be algebraically correct yet technically wrong when assumptions fail or the population or system boundary changes. Validity limit: For independent binary observations, pi=σ(wᵀxi+b) and log-likelihood is Σ[yi ln pi+(1−yi)ln(1−pi)]. The sigmoid-only transform is not the estimation objective; maximum likelihood chooses parameters from data. Complete separation can make unregularized Source: scikit-learn User Guide, §1.1 Linear Models: Logistic regression and log loss.
The stated units are: p and labels are dimensionless; negative log-likelihood is in nats with natural logarithms. Convert values to a consistent unit system before substitution; counts, percentages and dimensionless ratios are not interchangeable. The variable list states the role of each symbol. Dimensional analysis catches many errors but does not replace checking the formula's assumptions. Validity limit: For independent binary observations, pi=σ(wᵀxi+b) and log-likelihood is Σ[yi ln pi+(1−yi)ln(1−pi)]. The sigmoid-only transform is not the estimation objective; maximum likelihood chooses parameters from data. Complete separation can make unregularized Source: scikit-learn User Guide, §1.1 Linear Models: Logistic regression and log loss.
Comparison helps when both quantities address the same question but emphasize different properties. Report the definition, input data, threshold or averaging with the value. The source scikit-learn User Guide, §1.1 Linear Models: Logistic regression and log loss. supports the definition used here; other conventions can differ. Choose the measure to match the learning or analysis goal. Validity limit: For independent binary observations, pi=σ(wᵀxi+b) and log-likelihood is Σ[yi ln pi+(1−yi)ln(1−pi)]. The sigmoid-only transform is not the estimation objective; maximum likelihood chooses parameters from data. Complete separation can make unregularized Source: scikit-learn User Guide, §1.1 Linear Models: Logistic regression and log loss.
Quanta exam set
Curated exam set for "Logistic regression as a Bernoulli likelihood":
Question (front)
Which formula describes Logistic regression as a Bernoulli likelihood?
Answer in your set
Question (front)
How do you rearrange Logistic regression as a Bernoulli likelihood for Defining relation?
Answer in your set
Question (front)
Which common mistake happens with Logistic regression as a Bernoulli likelihood?
Answer in your set
+ 8 more cards: units, variables, derivation, example, exam task
The formula set contains 11 cards. After importing, review them and start practicing; your ratings determine later review intervals.
This list names subject references and further reading. A page or section number appears when it is part of the reference; these are not verbatim quotations.
Create a curated FSRS exam set for Bernoulli negative log-likelihood: formula recall, variables, derivation, rearrangement, worked example, common mistakes and exam context.
Curated formula set · LaTeX · FSRS spaced repetition · import from Essential