Computer Science · Theme A: Concepts of computer science
A4.3 — Machine learning approaches
Computer Science · SL / HL · syllabus-mapped notes
CS_A4.3.1
Linear regression for continuous outcomes
Predictor and response variables, slope and intercept, and fit measured by r squared.
Full note — freeThis card is HL only. You must be able to explain how linear regression predicts a continuous outcome by fitting a straight line to the data. Predictor and response variables It models the relationship between an independent (predictor) variable and a dependent (response) variable, written y = mx + c. Slope and intercept The slope (m) is how much y changes for each one-unit increase in x; the intercept (c) is the predicted value of y when x is 0. Goodness of fit How well the line fits the data is often assessed with r² (the coefficient of determination), between 0 and 1: values near 1 mean the model explains most of the variation.
CS_A4.3.2
Classification: K-NN and decision trees
Predicting discrete categories from labelled data with K-NN and decision trees.
This card is HL only. You must be able to explain how classification in supervised learning predicts a discrete, categorical outcome by learning from existing labelled data. The two named algorithms are K-NN and decision trees. K-Nearest Neighbours (K-NN) : classifies a new data point …
CS_A4.3.3
Evaluating models and hyperparameter tuning
Accuracy, precision, recall, F1, tuning, and overfitting versus underfitting.
This card is HL only. You must be able to explain how supervised models are evaluated and the role of hyperparameter tuning . Evaluation metrics Accuracy : the fraction of all predictions that are correct. Precision : of the cases predicted positive, how many really …
CS_A4.3.4
Clustering in unsupervised learning
Grouping data by similarities in its features.
This card is HL only. You must be able to describe how clustering techniques in unsupervised learning group data based on similarities in its features. The data is unlabelled : the algorithm groups points that are close or similar in their features into clusters, without …
CS_A4.3.5
Association-rule learning
Uncovering relations between attributes in large data sets.
This card is HL only. You must be able to describe how learning techniques using the association rule uncover relationships between different attributes in large data sets. Association-rule mining looks for attributes that frequently occur together and expresses them as rules of the form "if …
CS_A4.3.6
Reinforcement learning
An agent learning from its environment via cumulative reward.
This card is HL only. You must be able to describe how an agent learns to make decisions by interacting with its environment in reinforcement learning . Cumulative reward The agent's goal is to maximise the total reward gathered over time, not just the next …
CS_A4.3.7
Genetic algorithms
Population, fitness, selection, crossover and mutation applied to optimization.
This card is HL only. You must be able to describe the application of genetic algorithms , which imitate natural evolution to search for good solutions. Example concepts : Population : a set of candidate solutions. Fitness function : measures how good each candidate is. …
CS_A4.3.8
ANNs: perceptron and multi-layer networks
The structure and function of artificial neural networks, with perceptron and MLP sketches.
This card is HL only. You must be able to outline the structure and function of artificial neural networks (ANNs) and how multi-layer networks model complex patterns. An ANN simulates interconnected nodes, or "neurons", that process and learn from input data, enabling tasks such as …
CS_A4.3.9
Convolutional neural networks (CNNs)
Learning spatial hierarchies of features in images through its layers.
This card is HL only. You must be able to describe how convolutional neural networks (CNNs) are designed to adaptively learn spatial hierarchies of features in images (edges, then shapes, then objects). Basic architecture (in order): Input layer : the raw image (pixels). Convolutional layers …
CS_A4.3.10
Model selection and comparison
Why different algorithms suit different data and problems.
This card is HL only. You must be able to explain the importance of model selection and comparison : choosing the most suitable algorithm for a given task. Different algorithms can yield very different results depending on the data and the type of problem: no …
