Logistic regression Flashcards
For the binary classification problem, define the log ratio as:
a = log [(p(C1|x) / p(C2|x)]
= log[(p(x|C1)p(C1) / p(x|C2)p(C2)
What is sigmoid(a) = 1/(1 + exp(-a))
sigmoid(a) = p(C1|x)
How can we generalize logistic regression to K classes ?
Use softmax,
p(Ck|x) = p(x|Ck)p(Ck) / sum[p(x|Ci)p(Ci)]
In the usual binary logistic regression setting, what kind of distribution is the likelihood?
Bernoullli
What is the NLL (Negative log likelihood) of the binary logistic regression?
- sum y_i log (mu_i) + (1 - y_i) log ( 1 - mu_i)
What is the derivative of the sigmoid, o(z)?
o(z) ( 1 - o(z))
What is the gradient of the NLL for binary logistic regression?
(y - my)^T*X
Does the NLL of binary logistic regression have a unique global optimum?
Yes, but no closed for solutions exist
How can we solve the problem that under Bayesian logistic regression, the integral of the marginal likelihood is intractable?
Use approximations, for example using the laplace approximation by expanding -log p_hat(x) using the second order taylor expansion around the mode, recognizing the mean and covariance matrix in the resulting normal distrubution.