2.2.1. Dataset

The data obtained by the eye-tracking experiments, for each person, provide the following information:


Regular eye movements alternate between saccades and visual fixations. A fixation is the maintaining of the visual gaze on a single location. A saccade is a quick, simultaneous movement of both eyes between what happens among two or more phases of fixation in the same direction.

In case of blinking, the device loses the signal and it results in "NaN" (Not a Number) values either for the position (*<sup>x</sup>*, *y*) on the screen and for the pupil sizes. Pupil sizes were not taken into account for the data processing described in the following.

The results of the eye-tracking experiments for 376 subjects were divided into three classes: 46 patients with extrapyramidal syndrome, 284 affected by chronic pain and 46 controls.

It is worth noting that the collected dataset is significantly unbalanced, a problem naturally attributable to the type of pathologies to be prognosed. In particular:


Therefore, an alteration in the scan-path for an extrapyramidal patient is invariably pathological, while a similar alteration evidenced in a patient affected by chronic pain must be treated with caution.

#### 2.2.2. Generated Scan-Path Sequences

Starting from the data previously shown, we dealt with the generation of the scan-path sequences as follows.

The goal here is to use the information of the data to reconstruct the scan-path of an individual during the test as a sequence of symbols, associating a letter or a number for fixations on the ROIs accordingly, and the special character "!" for fixations outside the ROIs (black area). In other words, we generated a string *T* = *t*1 ... *tn* over the alphabet A = {1, 2, 3, 4, 5, *A*, *B*, *C*, *D*, *E*, !}. After having determined the centroids of each symbol in the TMT stimulus image, we have calculated the minimum distance between any pair of centroids, and we set a threshold equal to its half. Then, for every fixation ID, we computed the distance from the fixation area to the closer centroid, and we selected it as the associated symbol if the distance was less than the threshold, or "!" otherwise.

For instance, a generated sequence can have the following form:
