Supervised Machine Learning

In supervised learning, the machine is enabled to predict based on labeled data fed to it. In layman’s terms, we can easily say that the models are trained on labeled examples and make predictions on unlabelled examples.

We discussed labeled and unlabelled examples above. Let us see what they are.

Labeled Data

Includes one or more features and a label. Let us see an example to predict the value of a house. The features here are four and one label:

  • Features: Bedrooms, Bathrooms, Balcony, Area, Property Age
  • Label: Property Price

Here it is:

BedroomsBathroomsBalconyArea (Sq. ft)Property AgeProperty Price
42215005$290,000
211120015$120,000
53220007$340,000
33114005$250,000
1117003$100,000

Unlabelled Data

Includes one or more features but no label. Let us see the same example to predict the value of a house. The features here are four but no label:

  • Features: Bedrooms, Bathrooms, Balcony, Area, Property Age
  • Label: None (no target variable, such as Property Price)

Here it is:

BedroomsBathroomsBalconyArea (Sq. ft)Property Age
42215005
211120015
53220007
33114005
1117003

Let us now summarize:

  • The tasks are well-defined in supervised learning.
  • The prediction is based on labeled data in supervised learning.
  • The prediction or decisions are based on past data in supervised learning

Example – Supervised Learning

Let us see an example. Our data includes Hexagon and Star shapes. The below image demonstrates a machine learning supervised learning process:

  • Past Data: On the left, there are two sets of data: one with three hexagons and one with three star shapes.
  • New Data: At the bottom, there’s new data, featuring one hexagon and one star.
  • Machine Learning Model: The center showcases our machine learning model.
  • Predicted Output: On the right, you see the predicted output based on the new data, like the past data sets.

The arrows show how past data and new data flow into the model, which then predicts the output. This image simplifies understanding how machine learning uses past data to make predictions on new data:

Supervised Machine Learning

The following are the two types of Supervised learning:

  • Classification
  • Regression

Classification

Classification is a type of supervised learning where the goal is to predict a categorical output variable based on one or more input features.

The following are the examples of Classification:

  • Spam vs. Not Spam email classification
  • Cancer diagnosis based on tumor characteristics
  • Handwritten digit recognition (e.g., MNIST dataset)

Algorithms like Decision Trees, K-Nearest Neighbors, Support Vector Machines, Naïve Bayes, etc. Neural Networks are used for classification.

Here are some more examples of Classification:

  • Email Spam Detection: Classifying email spam from your emails
  • Sentiment Analysis: Determining if a piece of text is positive, negative, or neutral.
  • Image Recognition: Identifying objects in an image, like distinguishing between cats and dogs.
  • Medical Diagnosis: Classifying medical images as cancerous or non-cancerous.

Regression

Regression is a type of supervised learning where the goal is to predict a continuous output variable based on one or more input features.

The following are the examples of Regression:

  • Predicting house prices based on features like number of bedrooms, square footage, and location.
  • Forecasting stock prices based on historical data and economic indicators.
  • Predicting a person’s height based on their age, gender, and weight.
While regression is often associated with numerical data prediction, some types of regression can handle other data types:
  • Linear Regression: Predicts a continuous numerical output variable.
  • Logistic Regression: Predicts a binary categorical output variable (0/1, yes/no, etc.).
  • Ordinal Regression: Predicts an ordinal categorical output variable (e.g., ranking, rating).
  • Poisson Regression: Predicts a count output variable (e.g., number of accidents, number of sales).

Here are some more examples of Regression:

  • Age Prediction: Predicting the age of a person based on height, weight, health, and other factors.
  • House Price Prediction: Predicting house price based on number of rooms, bathrooms, balcony, parking, location, etc.
  • Stock Price Forecasting: Predicting future stock prices based on historical data.
  • Weather Prediction: Estimating future temperatures or rainfall amounts.
  • Forecasting Sales: Predicting future sales based on past sales data.

Both the classification and regression concepts will be discussed later in the Machine Learning – Classification and Machine Learning – Regression sections.


If you liked the tutorial, spread the word and share the link and our website Studyopedia with others.


For Videos, Join Our YouTube Channel: Join Now


Read More:

Machine Learning Tutorial
Studyopedia Editorial Staff
contact@studyopedia.com

We work to create programming tutorials for all.

No Comments

Post A Comment

Discover more from Studyopedia

Subscribe now to keep reading and get access to the full archive.

Continue reading