Deriving the loss function for logistic regression

Hello everyone,

I understand that this may not really be within the scope of the course, but I’d like to see how we arrived at the formula used for the logistic loss function (or a reference). I’m as interested in the math as every other process and so did like to do/understand all of the derivations on the side as i follow through. Thank you.

PS: Please note that I am asking about the actual loss function formulas when the targets are 0 and 1 and not the rewritten formula used for easier implemenation

Hello @Chukwuka_Chikwendu,

This is my first attempt. Please take a look at section 12.2.1 and see if that satisfies you. If not, please share with me your opinion and I will see what I can do.



You can search on the internet for “derivative of logistic cost function” and get many hits.