*5.2. Wasserstein Analysis*

The distributional representation of the stores enables the definition of an ideal store that can be used to build a Wasserstein-based ranking. The histogram associated with the ideal store has the entire mass concentrated on the bin of the most favorable assessment. For instance, Figure 7 shows the ideal univariate and bivariate histograms. This definition can be naturally extended to multi-dimensional histograms.

**Figure 7.** Univariate histogram associated with the ideal store (**left**): KPI values are on the x-axis, and their relative frequencies are on the y-axis. Bivariate histogram associated with the ideal store (**right**): KPI values related to *KPIi* and *KPIj* are on the x-axis and y-axis, respectively, and each bin is colored by their relative frequencies.

Given such a histogram, it is now possible to build a ranking computing the Wasserstein distance between the histograms associated with each store and the ideal one. In this way, the ranking is built upon the entire distributions of the KPIs' values and not only considering their means. To highlight the advantages of this framework, Figure 8 shows the correlation between the distances of the stores for the ideal and different statistics of the KPIs' distributions while considering histograms in one to four dimensions.

**Figure 8.** Pearson correlation between the distances of stores from the ideal and four statistics (mean, variance, kurtosis and skewness).

In the case of univariate histograms related to the KPI "selection", the correlation between the distance from the ideal and the mean is at a maximum; therefore, the rankings built upon the mean and the distance from being ideal are the same. By increasing the dimensionality of the data, the correlation of the Wasserstein distance with the mean tends to decrease, but the correlation with other statistics, such as kurtosis and skewness, tends to increase. The Wasserstein distance is able to capture other aspects or statistics of a distribution rather than just the mean, resulting in a more robust ranking.
