makautnotes

0.2 Types of Machine Learning★★★

Must-do3/4 recent papersup to 6M⏱ 4 min
PYQs4
  • Discuss the different types of Machine Learning. 2022-23 6M recent
  • What is unsupervised learning? → Learning from unlabelled data to find hidden patterns or groups 2024-25 1M recent
  • The prior goal of an unsupervised learning model is to determine the ______. → Hidden patterns (structure or groupings) in the data 2023-24 1M recent
  • Fraud detection, image classification, diagnostics and customer retention are applications of ______ learning. → Supervised 2023-24 1M recent

Three Ways to Learn


Types of Machine Learning PYQ 6M

flowchart TD
    A["<b>Data</b>"]:::blue --> B{"Labelled<br>examples?"}:::amber
    B -->|"Yes"| C["<b>Supervised</b>"]:::green
    B -->|"No"| D{"Learns from<br>rewards?"}:::amber
    D -->|"Yes"| E["<b>Reinforcement</b>"]:::green
    D -->|"No"| F["<b>Unsupervised</b>"]:::green
    classDef blue fill:#5b84d424,stroke:#5b84d480
    classDef amber fill:#d6a24424,stroke:#d6a24480
    classDef red fill:#d0707024,stroke:#d0707080
    classDef green fill:#52a86e24,stroke:#52a86e80

Supervised Learning

Supervised learning is learning from labelled data: each example has an input x and the correct output y, and the model learns the mapping x → y.

Two kinds (→ 1.1)

  1. Classification: output is a category. Example: spam / not spam; disease yes / no.
  2. Regression: output is a number. Example: house price; tomorrow's temperature.

Algorithms: linear and logistic regression, KNN, decision trees, Naive Bayes, SVM.


Unsupervised Learning PYQ 1M

Unsupervised learning is learning from unlabelled data, where the goal is to find hidden structure, patterns or groupings.

Main tasks

  1. Clustering: group similar items. Example: customer segmentation (→ 2.1).
  2. Dimensionality reduction: compress many features into few (→ 2.4).
  3. Association rules: find items that occur together. Example: "bread → butter" in shopping baskets.

Algorithms: K-means, hierarchical clustering, PCA, Apriori.


Reinforcement Learning

Reinforcement learning (RL) is learning by trial and error: an agent acts in an environment and learns from rewards and penalties to maximise total reward (→ 5.4).


Other Types


Supervised vs Unsupervised vs Reinforcement

Basis Supervised Unsupervised Reinforcement
Data labelled (x, y) unlabelled (x only) no fixed dataset; experience from actions
Feedback correct answer for every example none reward or penalty after actions
Goal predict outputs for new inputs find hidden patterns maximise total reward
Tasks classification, regression clustering, dimensionality reduction, association control, decision sequences
Algorithms regression, KNN, trees, SVM K-means, PCA, Apriori Q-learning, policy gradients
Example spam detection customer segmentation game playing, robots

Matching Applications to Types PYQ 1M

Application Type Why
fraud detection supervised past transactions labelled fraud / genuine
image classification supervised images labelled with classes
medical diagnostics supervised records labelled with diagnosis
customer retention (churn) supervised past customers labelled stayed / left
customer segmentation unsupervised no labels; find groups
targeted marketing groups unsupervised group by behaviour
market basket analysis unsupervised find items bought together
game AI, robot navigation reinforcement learn by rewards

Choosing the Type: A Movie-Review Dataset

⚡ Quick recall
  • Supervised? → labelled data, learn x → y · classification (category) and regression (number)
  • Unsupervised? → unlabelled data · goal: hidden patterns / structure / groups · clustering, dimensionality reduction, association
  • Reinforcement? → agent, actions, rewards, trial and error
  • Others? → semi-supervised · active · online
  • Fraud, image classification, diagnostics, retention? → supervised
  • Labelled movie reviews? → supervised classification (sentiment)
Unit 0 · 0/4