## 4 Client Segmentation by Clustering
In our research we are interested in calculating the internal properties of groups of tourist clients attending to a specific criterion of non-verbal communication. The internal indices to use in our proposal are appropriate because their aim is to identify sets of clusters that are compact, with a small variance between members of the cluster, and well separated, where the means of different clusters are sufficiently far apart, as compared to the within cluster variance. Three are the most important options in this area: the Dunn index, the Silhouette index and the Davies--Bouldin index. For a given assignment of clusters, a higher Dunn index indicates better clustering, and its advantages are clear over the other feasible alternatives when the number of clusters is small. This feature of our dataset gave us the opportunity to choose the Dunn index to assess the quality of the clusters. In the experiments carried out in reference [55] of our manuscript, the authors found that the Dunn index attains better rank correlation and therefore is widely recommended. This guarantees us that the clusters of tourist clients are of high quality, which has a positive impact on the results. The Dunn index is given by the ratio between the smallest distance between two groups \(G_{i},\ G_{j}\), and the size of the largest group (Equations (1)-(3)). \[Dunn(G)=\frac{\min\limits_{i,j\in[1,\ |G|]}\{d\big{(}G_{i},G_{j}\big{)}\}}{ \max\limits_{i\in[1,\ |G|]}\Delta(G_{i})} \tag{1}\]  
\[d\big{(}G_{i},G_{j}\big{)}=HEOM\big{(}\overline{g_{i}},\overline{g_{j}}\big{)} \tag{2}\]  
\[\Delta(G_{i})=\frac{\sum_{x,y\in G_{i}}HEOM(x,y)}{|G_{i}|*(|G_{i}|-1)} \tag{3}\]  
There are several ways to define the distance between groups and the size of a group. In this case, the EEUC software uses the dissimilarity between the centroids \(\overline{g_{i}},\overline{g_{j}}\), and the average intergroup dissimilarity, respectively. As a measure of dissimilarity, the HEOM (Heterogeneous Euclidean Overlapping Metric) function is used, which allows the handling of any type of data [56]. There are an infinite number of functions that are useful for measuring dissimilarity between patterns. The most famous are the Minkowski distance or metric functions, among which three cases stand out: the city block distance (order 1), the Euclidean distance (order 2), and the chessboard distance (infinite order). However, all these distance functions are only useful for PATTERNS WITH NUMERICAL FEATURES. If in the patterns there are categorical features, or mixed or lack of information (missing values), these distance functions totally lose their usefulness. That is when the Heterogeneous Euclidean Overlapping Metric function becomes important, which is one of the best options for measuring dissimilarity between incomplete patterns with mixed features. For this reason, in our research the Heterogeneous Euclidean Overlapping Metric function is adopted as a measure of dissimilarity, given the obvious advantages it exhibits. The positive effects on the bottom line are obvious. The HEOM function is shown in Equations (4)-(7). \[HEOM(x,y)=\sqrt{\sum_{A_{i}\in A}d_{i}(x_{i},y_{i})^{2}} \tag{4}\]  
\[d_{i}(x_{i},y_{i})= \begin{cases}1&\text{if missing}\\ overlap(x_{i},y_{i})&\text{if nominal}\\ rn_{-}diff(x_{i},y_{i})&\text{is numeric}\end{cases}  \tag{5}\]  
\[overlap(x_{i},y_{i})= \begin{cases}0&\text{if }x_{i}=y_{i}\\ 1&\text{otherwise}\end{cases}  \tag{6}\]  
\[rn_{diff(x_{i},y_{i})}=\frac{|x_{i}-y_{i}|}{max_{i}-min_{i}} \tag{7}\]  
Figure 3 shows the results of applying [PERSON]'s index to the grouping algorithms compared. As can be seen, the highest quality grouping is the one corresponding to the KMSF algorithm, with six groups formed, since, at this point, the [PERSON] index reaches its maximum value. The resulting groups were inspected manually by the director of the Quality and Customer Service Department of the Sol Cayo Guillermo hotel and received the approval of this expert, with more than 20 years of experience in the tourism field.