Multiple choices questions in Machine learning. Interview questions on machine learning, quiz questions for data scientist answers explained, what is the cost function of logistic regression? Why the cost function used in linear regression cannot be used in logistic regression? Why the cost function of logistic regression is convex?
Machine Learning MCQ - Cost function of logistic regression is convex
1. Which of the
following statements about logistic regression are correct?
a) Logistic
regression uses the squared error as the loss function
b) Logistic
regression assumes that each class’s points are generated from a Gaussian
distribution
c) The cost
function of logistic regression is concave
d) The cost
function of logistic regression is convex
Answer: (d) The cost function of logistic regression is convex Gradient descent will converge into global minimum only if the cost function is convex in the case of logistic regression.
Can we use the same cost function used in linear regression for logistic regression?If we use the
cost function of linear regression (Mean Squared Error) in logistic
regression, we end up with a non-convex function with many local minimums. In
this case, it is very difficult to find the global minimum. This strange
outcome is due to the fact that in logistic regression we have the sigmoid
function around, which is non-linear (i.e. not a line). |
No comments:
Post a Comment