All right, so now you understand it better.
But remember that these are the training set results.
Therefore all these customers that we see here are actually in the training set.
Therefore these are customers with which or logistic regression model was trained.
And therefore that's kind of easy to provide such results
because these are exactly the observations of the training.
But now what we would like to see is how our logistic regression model
was able to perform on new observations, meaning
on the observations of the test set, the customers of the test set.
Because indeed the customers of the test set are new customers
with which our logistic regression model wasn't trained.
And so we have to see if our logistic regression
model was still able to separate.
Well, the two classes, meaning the customers who bought SUV
and the customers who didn't buy the SUV, even despite the fact
that these are new customers on which the model wasn't trained.
And that's exactly what we're about to see now when visualizing the test results.
We already executed the cell here.
And so these are the test results.
And still our logistic regression model was perfectly able to separate.
Well the two classes zero.
You know all those red points here.
And one all those green points.
There are still some incorrect predictions of course, like this customer
who in reality didn't buy the new the brand new beautiful SUV.
But was predicted to buy it.
And a few incorrect predictions here of the other class.
Meaning these customers who in reality but the SUV
but were predicted not to because they fall in the red region.
All right.
And so how can we conclude here?
What should we conclude and what are the takeaways
we should get for our future class fixation models.
Well, first the logistic regression model does a very good job
at separating our two classes
and therefore at predicting whether the customers but the SUV.
But we actually would hope to build a model
that has less prediction errors.
And how can we build one.
What would we need to get, you know, as the prediction curve in order
not to predict incorrectly all these wrong predictions here.
You know, all these customers here.
Well, we actually would need a prediction boundary
that is something else than a straight line.
Because even if you try to rotate your prediction line, for example,
to be like that, well it will still catch many incorrect predictions.
So what we would need to get, you know, ultimately is some kind of curve,
some kind of prediction curve that goes this way, catches
all the red points, you know, all the red customers here
and then go around like this in order to catch all the red points.
The red customers, and leave
all the green points to green customers inside the green region.
And well, as you might guess, this is what we might be able
to get with nonlinear classifiers.
I won't tell you more now, but be ready for some even more performance
classification models that managed to separate.
Even better, these two classes.
So there we go.
That was the big part of the job. You did it.
And now follow me
in the next sections to implement the other classification models.
And until then, enjoy machine learning.