Once the training and test datasets have been smoothed and normalised, the MATLAB script cycles through each year of the test technology data records being considered and calculates the Euclidean distance between the current test data point and all possible training technology data points. This process is illustrated by Gao as shown in Fig. \ref{405215}: