2
$\begingroup$

I am taking the coursera machine learning course by Andrew Ng and have run into some issues.

I do not understand why the answers are like this?

enter image description here

The equations seem to me the same but the graphs are totally different

enter image description here

$\endgroup$
1
  • $\begingroup$ Please provide a logical explanation of why a decision boundary is needed, why a classifier is needed, and why predicted probabilities from logistic regression are deficient. Logistic regression is not a classifier. $\endgroup$ Jun 1, 2015 at 12:30

1 Answer 1

6
$\begingroup$

The pictures are a bit misleading in the sense that the outcome of the equations presented, the p-value, could also be plotted on a z-axis. Look at the picture below.

enter image description here

(Picture taken from http://strijov.com/sources/demoDataGen.php). Take care that the picture is illustrative only and is not related to your example perse, although the variable names match. p-value should be interpreted in this context as the probability of the dependent variable equaling a "success" or 1. (Thanks @Scortchi)

In Question 2 you can see that the coefficient of x1 is 0. This means that changing x1 does not affect the p-value. Only changing x2 affects the p-value. If the p-values values form a wave, then x1 would be the beach, to put it practically.

The decision boundary depicted is actually the line that separates the p-value that are smaller and larger than 0.5. Since this line is not affected by x1, the line is parallel to the x1 axis: changing x1 does not influence the p-values.

The illustration might resemble by chance your second example, where the coefficient of x2 is zero.

$\endgroup$
2
  • 2
    $\begingroup$ (+1) But the probability that $Y=1$ is not called a "p-value", which has a quite specific meaning in Statistics. $\endgroup$ Jun 1, 2015 at 11:43
  • $\begingroup$ Point taken. I added exta information. $\endgroup$
    – spdrnl
    Jun 1, 2015 at 11:49

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.