Skip to content
nonconvexcard

In-sample calibration of logistic regression

ProofIntermediate⏱ 30 minClassical MLcalibrationscore equationslimits

Problem

Show that at any stationary point X⊤p=X⊤yX^\top p = X^\top y, and deduce that with an intercept the predicted and observed positive counts agree exactly. Then explain precisely why this is a weak form of calibration.

Write a complete argument. Every inequality you use should be one you could state precisely.

Solution

Opening this before you have a real attempt on paper is the fastest way to feel like you understand something you cannot reproduce.

Related problems

All problems
SolvedProblemFieldTypeDifficultyTime
Convexity of the logistic lossClassical MLProofBeginner15 min
IRLS is a weighted least-squares solveClassical MLProofIntermediate30 min
Logistic regression diverges on separable dataClassical MLProofIntermediate30 min
The floor that correlated failure puts under redundancyAI SystemsProofIntermediate30 min