top of page


Have you ever given a thought on how Gmail is able to segregate your emails into different folders such as “Primary”, “Social”, “Promotions”, and etc.?

Or let’s say you are sitting on your couch and browsing Netflix, you get a list of movies/series recommendations, which are very similar to your past watched history. Ever wondered how is that possible? Does the machine know you personally to suggest movies/ series similar to your interests?

All these are the applications of Machine Learning, a branch of Artificial Intelligence. Machine learning which focuses mainly on machines, learning from their past experiences. As per Computer Scientist “Arthur Samuel”, Machine Learning is a field of study that gives computers the ability to learn without being explicitly programmed”.

Still confused?

Let us consider an analogy.

When a child goes to a primary school, the teacher starts with the alphabets. The teacher shows picture of letter “A” to the child and tells him that it is “A”. The teacher repeats the process again and again till the student learns all the alphabets. Here, the student is being trained. Once the training is complete, the teacher conducts test to verify how well student has learned.

Now, we will use the same methodology to train the machine.

Let’s say we have a machine who knows absolutely nothing. We start training the machine in a similar way. Machine has no idea about what is “A” or “B”. So, we start by showing our machine various pictures of letter “A” and teaching it that it is “A”. When the training is complete, we test the machine by showing it letter “A” of different fonts and styles. If the machine is able to identify the letter accurately, it means the machine was well trained, and if not, then in order to increase the efficiency of our machine, we will have to train the machine with more images of “A” of different fonts and styles. We again test our machine and check its accuracy.

“More training you give, more accurate your machine will become”, is the concept of Machine Learning.


Machine Learning can be broadly classified into three categories:-

1. Supervised Learning

2. Unsupervised Learning

3. Reinforcement Learning

Supervised Learning

Supervised learning, as the name suggests, indicates the presence of a supervisor as teacher. It is a type of learning in which we teach our machine using data which is well labelled.

For example, consider three baskets of fruits and each fruit is tagged with a label. Now, the machine is trained on this labelled data.

Once the training is done, machine is fed with the test data or new data to check how well the training has been done.Supervised learning is further classified into regression and classification problem. The difference between the two problems is that the dependent variable is numerical for regression and categorical for classification.Before discussing regression and classification problems, let us understand few terminologies.

Categorical variable are the variables that can be put into categories. For example, severity of a disease i.e. “mild”,” severe”, “highly severe”.

Continuous variable are the variables that can take infinite number of values within an interval. For example, “time” and “weight”.

Dependent variable: The variable whose value is to be predicted is called dependent variable.

Independent variable: The variable whose value is used for prediction of dependent variable is called independent variable.

Regression: we attempt to determine the relationship between two or more variables. In regression analysis, there are two types of variables i.e. dependent variable(Y) and independent variable(X). We will define function to understand the relationship and predict the dependent variable. The function is expressed as Y=f(x)

For example, predicting the annual expenditure (dependent variable) of a person by using his annual income (independent variable).

Classification: As the name suggests, to classify into categories. A classification is done when the dependent variable is a categorical variable, such as yes or no, black or white. Classification models include Logistic regression, Decision tree, Random forest etc. For example, predicting whether a person will default on his next loan payment on the basis of his income.


Unsupervised Learning

Unlike supervised learning, there is no supervisor as a teacher in the unsupervised learning which means no teaching is provided to the machine. Also, the training data does not have any labeling associated to it. Here, the machine groups unsorted data according to similarities, patterns without any prior training of data.

Refer to the snip attached below:-

In this type of learning methodology (algorithm), the machine understands the underlying structure of the data to identify similar patterns. The data which is similar in nature is grouped together. In the above example, the machine identifies the structure of pyramid and groups it together same happens with the other two structures.

Unsupervised machine learning can be classified into two categories i.e. “Clustering” and “Association”.

Clustering: It is performed when we aim to partition a set of objects in such a way that objects in the same cluster are more similar to each other than to those in other clusters. In other words, clusters should be homogenous within and heterogeneous amongst. For example, cluster based on the sentiments of the tweet in the set of tweets.

Association: An association rule comes into picture where you want to discover rules that describe large portions of your data, such as people that buy X also tend to buy Y. For example, findings in the sales data of a supermarket would indicate that if a customer buys bread and butter together, they are likely to buy tomato ketchup. Such sort of information can be used as the basis for decisions about marketing activities such as promotions.


Reinforcement Learning

In reinforcement learning, the algorithm learns through a system of rewards and punishments. Consider the example of baskets of fruits, Let say we feed the machine the image of apple and if it labels it as apple then it will be rewarded (i.e. it is given positive points). However, if it labels apple as banana then it will be given negative points. The greed of getting more and more reward points lets the machine make thousands of decisions and this is how the machine is trained.

Refer to the snip attached below:-

Author: Sarabjeet Singh

263 views0 comments


bottom of page