## 4 Experimental Results
### Comparative Study for the Automatic Selection of the Number of Clusters  
Choosing the optimal number of clusters is usually a tricky problem for all clustering algorithms. In our previous work, we considered only two clusters in order to differentiate between congested and fluid zones [19]. However, selecting a fixed number of clusters for all periods causes a strong restriction. In this section, we present a comparative study be  
Figure 8: The mean values of connected clusters’ dissimilarity versus snake length computed as a percentage of the size of the network of roads. Figure 9: The mean values of connected clusters’ dissimilarity versus the weight coefficient \(\phi\). tween the density peak, the eigengap [25] and the modularity [12] methods to automatically detect the number of clusters. In the case of the density peak, we choose the cut-off distance that minimizes the potential entropy of data for all time periods, we compute the local density \(\rho_{i}\) and the parameter \(\theta_{i}\), and we identify the cluster centers by calculating the probability density function and choosing the appropriate threshold by selecting the values of \(\alpha_{0}\) and \(\beta_{0}\) based on [32] (Figure 10). The clustering results are analyzed in the case of spectral clustering using the density peaks, the modularity and the eigengap for the automatic selection of the number of clusters. We consider the time period \(t=6\) in order to test the three methods on a different number of clusters. We plot the results of the clustering of Amsterdam road networks (Figure 11), and we compute the average speed and the standard deviation in each cluster for time period \(t=6\) (Table 1). It is shown that the obtained clusters have small standard deviation values, which proves a promising performance in separating homogeneous connected clusters. Moreover, the density peak algorithm is better in the partitioning of the transportation network into homogeneous partitions with separated average speed. Figure 11: Clustering results for the time period \(t=6\) in the case of the density peak (**a**), modularity (**b**) and eigengap (**c**). Figure 10: Decision graph for the time period \(t=6\) using the density peak algorithm and the probability density function. The results of the clustering method with the histogram of speeds for the density peak, the modularity and the eigengap methods are shown in Figures 12-14. It can be inferred from the clustering results that the density peak algorithm can separate the pockets of congestion better than the modularity and the eigengap methods. It is clear that, in the case of density peaks, the network has two main pockets of congestion, the cluster with small average speed represented by the red color and the cluster with a higher average speed represented by the Magenta color. The other two clusters detect part of the highway with medium average speed. Figure 15 shows the number of clusters obtained by applying the density peak, the modularity and the eigengap methods for each time period. We find that the number of clusters obtained by the density peaks algorithm is smaller than that of the modularity and the eigengap methods. Therefore, considering a smaller number of clusters makes the interpretation easier and helps to design more efficient control strategies [7]. Next, we run the IND, PCQ and PCM using the efficient spectral clustering algorithm with the density peak, the modularity and the eigengap for selecting the number of clusters. We report all costs in Table 2, where the best results are in bold face. Figure 14: Histogram of link speeds for the time period = 6 in the case of the eigengap. Figure 13: Histogram of link speeds for the time period = 6 in the case of the modularity.