2
$\begingroup$

I used gradient descent to obtain the coefficients for a logistic regression function. When I run my function on my test data set, I get values between 0 and 1.

If I get a predicted value of say, .7, and the actual value is 1, I count that as a correct prediction. I say that the prediction says there is a 70% chance the event happens. Is my reasoning correct?

$\endgroup$
2
$\begingroup$

Is the output of logistic regression the chance that the event occurs?

Yes.

If I get a predicted value of say, .7…. I say that the prediction says there is a 70% chance the event happens. Is my reasoning correct?

Yes.

If I get a predicted value of say, .7, and the actual value is 1, I count that as a correct prediction.… Is my reasoning correct?

Not really. What you're doing is evaluating the prediction according to zero–one loss: the prediction is either right enough (i.e., on the right side of $\tfrac{1}{2}$) or not. This isn't a proper scoring rule and hence not an appropriate way to assess the accuracy of predicted probabilities. Zero–one loss is appropriate for ordinary classification, but not for probabilistic classification.

$\endgroup$
  • $\begingroup$ The answer to the first question is strictly "no". It's not the chance the event occurs, it's the estimated chance that the event occurs (for that combination of predictors) under the fitted model. Since the fitted model won't be exactly correct (it won't fully capture the process that generated the data) and even if it were the estimate will have noise, it's not actually the chance that the event would occur on a new trial -- though hopefully it's close to it. $\endgroup$ – Glen_b -Reinstate Monica Jun 22 '17 at 0:29
  • $\begingroup$ @Glen_b Yes. (> '_' )> $\endgroup$ – Kodiologist Jun 22 '17 at 1:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.