Machine Learning

Machine learning, or ML for short, is a subfield of artificial intelligence (AI) that enables computers to learn patterns from data and make decisions or predictions without being explicitly programmed. Rather than following predefined rules, machine learning algorithms improve their performance over time as more data is processed.

Machine learning models require large amounts of data to learn patterns. Algorithms are used to analyse the data, adjusting the model's parameters along the way to improve accuracy. This is referred to as training the model. Trained models are then tested with new data to test its output. Once deployed, a model continues to refine its knowledge based on new data.

There are three types of machine learning:

  • Supervised learning.
  • Unsupervised learning.
  • Reinforcement learning.

Supervised learning

Supervised learning involves training a model using labelled data. The training data includes both feature values and known label values. It is used to train models by determining a relationship between the features and labels in past observations, to enable unknown labels to be predicted for features in future cases.

There are two forms of supervised learning, regression and classification. Regression involves the model predicting labels that are numeric. Classification produces labels that represent a categorisation, or class, and can be further subdivided into binary classification and multiclass classification.

Binary classification models predict one of two mutually exclusive outcomes, whereas multiclass classification predicts labels that represent one of multiple possible classes.

Examples of supervised learning algorithms include:

  • Linear Regression.
  • Logistic Regression.
  • Decision Trees.
  • Random Forests.
  • Support Vector Machines (SVMs).
  • K-Nearest Neighbors (k-NNs).
  • Gradient Boosting.
  • Naïve Bayes Algorithm.
  • Neural Networks (NNs).

Unsupervised learning

Unsupervised learning entails training models using data that contains feature values without any known labels. It is up to the algorithm to determine relationships between the features of the observations in the training data.

The most common form of unsupervised learning is clustering, where the algorithm identifies similarities between observations based on their features, and then groups them into discrete clusters.

Other forms of unsupervised learning include dimensionality reduction and association rule learning. Dimensionality reduction involves reducing the complexity of data while retaining relevant parts of its structure. It is particularly useful for simplifying large data sets and improving computational efficiency.

Association rule learning, or association rule mining, as it is also known, finds useful relationships between parameters of very large data sets.

Some examples of unsupervised learning algorithms include:

  • Clustering:
    • K-means Clustering.
    • Hierarchical Clustering.
    • Density-Based Clustering (DBSCAN).
    • Mean-Shift Clustering.
    • Spectral Clustering.
  • Dimensionality Reduction:
    • Principal Component Analysis (PCA).
    • Linear Discriminant Analysis.
    • Non-negative Matrix Factorisation (NMF).
    • Locally Linear Embedding (LLE).
    • Isomap.
    • PCA Kernel.
  • Association Rule Learning:
    • Apriori Algorithm.
    • FP-Growth Algorithm.
    • Eclat Algorithm.
    • Efficient Tree-based Algorithm.

Reinforcement learning

Reinforcement learning uses a trial-and-error approach to learning, where information is drawn from feedback given during the learning path. During the learning process a positive reward is assigned to each correct decision, with a negative reward given for an incorrect one. At the end of the learning process, the decisions of the algorithm are reassessed based on the final reward achieved.

Reinforcement learning is a powerful technique for decision-making and optimisation in dynamic environments.

Some examples of reinforcement learning algorithms include:

  • Markov process.
  • Q-learning.
  • Temporal difference (TD) methods.
  • Monte Carlo methods.