[MUSIC]
Now we've seen classification in a wide variety of settings and how we can really
use to predict a class like a positive or negative sentiment from data.
In the regression section, Amy talked about this block diagram that
really describes how a machine learning algorithm iterates through its data.
So now let’s take this same block diagram and work through it and
describe how it works out in the case of classification with sentiment analysis.
So how does it look for classification for
sentiment, so in this case,
the data is the text of the reviews, so
for each review, the text of review is
associated with a particular labeled sentiment
From that text of the review, we feed it to through a feature
extraction phase which gives us x, the inputs to our algorithm.
And this x here is going to be the word counts.
So word counts for every data point, for every review.
Now our Machine Learning model is going to take that input data.
And so the word counts, as well as some several parameters
which I'm calling here w-hat, which are the weights for each word.
Each word.
And from, combining these two, we're gonna output the predictions.
So if the score is greater than zero, it's gonna be positive.
If the score is less than zero, it's gonna be negative.
So this output here is the predicted sentiment.
And if we're just using the model, we would be done here.
But really, in the machine learning algorithm phase, we're gonna evaluate that
result and then feed it back into the algorithm to improve the parameters.
So we're gonna take the predicted sentiment, y-hat and
compare it with the true label for the sentiment.
So the sentiment label for each data point.
So that's gonna fit in and
our quality measure here is gonna be classification accuracy.
Classification accuracy.
And the machine learning algorithm, which we're gonna discuss in more detail
in the classification course, is gonna take that accuracy and try to improve it.
And the way the improvement works, is by updating the parameter w-hat.
And that's what the cycle for
machine learning algorithm classification would look like.
In this module, we've seen how to do classification.
We've looked at various examples of where it can be applied.
We'll talked about a few models for building classifications,
especially in the context of sentiment analysis, we saw some live demos.
And we even built a notebook where we built a classifier from data and
analyzed it.
And with this knowledge, you're ready to build an intelligent application
that uses a classifier at its core.
[MUSIC]