A-Z of AI in Healthcare

Unsupervised vs Supervised Learning

Two common methods for training AI algorithms in the context of healthcare.

Unsupervised and supervised learning are two different methods for training AI algorithms, specifically machine learning algorithms. 

Supervised learning 

Supervised learning involves training an AI algorithm to classify images, or make predictions by providing it with a labelled dataset and telling it what conclusions (or outputs) you want it to reach. For example, you might give a supervised algorithm a training dataset of labelled mammography scans and tell it you want it to learn how to identify breast cancer. 

Each image in the training dataset would be labelled as ‘cancer’ or ‘no cancer.’ The accuracy of that algorithm can then be tested by comparing its performance (i.e., how many images can it correctly classify) with that of a human clinician. These algorithms are used to automate tasks that humans already know how to do, such as pattern recognition. 

Unsupervised learning 

Unsupervised learning involves the use of AI algorithms to analyse datasets that have not been labelled. These algorithms are used to discover patterns or associations that humans were not previously aware of. For example, you might give an unsupervised algorithm an unlabelled dataset comprising the de-identified electronic health records (EHRs) of many patients and tell the algorithm to group them according to similarity (a task known as clustering). 

This new knowledge can then be used for research purposes, such as the discovery of new drugs or new uses for existing drugs, new potential causes of disease, new subgroups of patients, and more. 

Supervised and unsupervised learning are both machine learning techniques that are commonly used in the context of healthcare.

Supervised learning 

Supervised learning is used for classification and prediction tasks when the outcome of interest is known and can be ‘taught’ to an algorithm, by providing it with a labelled dataset during training. 

The goal of supervised learning is to ‘learn’ a function (or equation), so that when the algorithm is given a specific input, it will produce a desirable output. For example, given a dataset of chest X-Ray images, it will correctly classify those featuring known examples of cancerous lung tumours. Or given a person’s age, height, weight, and lifestyle, it will correctly predict their risk of developing cardiovascular disease within the next 10 years.  

The most common examples of supervised learning algorithms are:  

  • Support vector machine
    This is a classification algorithm, best used for binary data (i.e., in clinical situations where there are two clearly differentiated outputs), that classifies the data by finding the linear hyperplane (decision boundary) that separates all data points from one group from that of another group or class.  
  • K-nearest neighbour
    This is a classification algorithm that groups classes within the data based on similarity, assuming that proximity is equal to similarity i.e., that objects that are closer to each other in a dataset are more similar than those that are further apart. 
  • Logistic regression (linear and non-linear)
    Both linear and non-linear are examples of prediction algorithms that are used to fit a model that can predict the probability of a binary response belonging to one class or the other i.e., one clinical outcome or another (commonly used in risk stratification). 
  • Neural network
    This is a more complex predictive algorithm that consists of highly connected networks of neurons that try to identify the relationships between input and output variables. It is most useful when these relationships are complex and non-linear.   
  • Decision tree: This is a prediction algorithm that predicts responses to data inputs by following the decisions in the tree from one node to another, along branches, much like a flow diagram. The number of branches and values of the weights are determined in the training process. 

Supervised learning is relatively simple and its algorithms relatively interpretable or ‘explainable’ compared to unsupervised learning algorithms. Supervised learning algorithms are easier to validate as the outcome (or output) of interest is known and the baseline (human) performance is also known, so it’s easy to check whether the algorithm is doing its task well. However, supervised learning algorithms cannot be used to discover ‘new’ information and so are less useful for exploratory research. Furthermore, they rely heavily on the existence of large and accurately labelled datasets which are not always easy to access. 

Unsupervised learning

Unsupervised learning is used for clustering tasks when the outcome of interest is not necessarily known in advance and cannot be taught to the algorithm. Instead, an unsupervised learning algorithm must learn the outcome independently by inferring it from the unlabelled data it is provided with during training. 

The goal of unsupervised learning is typically to generate ‘new’ knowledge i.e., to find ‘hidden’ (or previously unknown) patterns in datasets, for example to identify new genotypes within genome datasets, or to identify anomalies and outliers in electronic health record datasets.

The most common examples of unsupervised algorithms are;

  • K-means clustering
    This is an algorithm that groups data containing continuous variables into a set number of clearly delineated, and non-overlapping, groups or ‘clusters.’  
  • Hierarchical clustering
    This is another clustering algorithm that can produce multiple different clustering solutions to the same ‘problem.’ The measure of dissimilarity desired between different clusters is set by the user. 
  • Principal component analysis
    This is an algorithm that ‘simplifies’ data by transforming high-dimensional data into ‘simpler’ linear functions that explain the total variance in the data – this is a process known as dimensionality reduction.. 

The advantages and disadvantages of unsupervised learning algorithms mirror those of supervised learning algorithms. For instance, unsupervised learning algorithms do not rely on large accurately labelled datasets, and can be used to determine non-linear and complex relationships that are not known in advance. However, they can be harder to evaluate and are often less ‘explainable’ than supervised algorithms.