## 4 Results and Discussion
### Spatial Analysis (Moran's I)  
The previous correlation analysis identified relationships between waiting times and variables such as transport mode, origin commune, and trip start time. However, that approach did not explicitly account for the spatial dimension. To determine whether high waiting times cluster geographically, Moran's I was applied to evaluate the presence of spatial autocorrelation in the variable of interest.  
As an initial step, a heat map (Figure 5) was generated to visualize the distribution of waiting times in Greater Valparaiso. Key observations include:  
* Vina del Mar exhibits various areas with very long waits (30-60 min), aligning with previous findings on congestion and high demand on certain urban bus routes (see Section 4.1.2).
* Valparaiso, though it records a high volume of trips, shows specific sectors with prolonged waits (e.g., parts of the hillside areas), albeit fewer than in Vina del Mar.
* Quilpue and outlying areas such as Placilla display some points with high waiting times, suggesting lower transport frequencies in peripheral regions.  
\begin{table}
\begin{tabular}{c c} \hline \hline
**Variable** & **Correlation** \\ \hline Waiting Time & 1.000000 \\ Origin Commune: Quilpue & 0.172530 \\ Trip Start Time & 0.105041 \\ Mode of Travel: Urban Bus & 0.104444 \\ Travel Time & 0.087626 \\ Origin Commune: Vina del Mar & 0.069582 \\ Final Income per Person & 0.056075 \\ Blocks Before & 0.042913 \\ Blocks After & 0.028846 \\ Origin Commune: Villa Alemana & 0.003395 \\ Mode of Travel: Metro Valparaiso & \(-\)0.026332 \\ Minutes Before & \(-\)0.044682 \\ Minutes After & \(-\)0.067452 \\ Mode of Travel: Taxi Colectivo & \(-\)0.098633 \\ Origin Commune: Valparaiso & \(-\)0.159795 \\ \hline \hline \end{tabular}
\end{table}
Table 5: Correlation analysis for prolonged waiting times.  
While the heat map provides an initial view of where long waits are concentrated, a more robust statistical analysis is required to confirm whether these concentrations are statistically significant or merely random. Moran's I serves this purpose.  
The calculation and detailed interpretation of Moran's I are presented in Section 3.2.2, so only the main findings are discussed here. Initially, k = 12 was set for the k-nearest neighbors (KNN) method, which generated 5723 disconnected components. After various tests, k = 20 was deemed more appropriate, reducing the number of disconnected points to 5641 (less than 0.5% of about 1.4 million trips), thus assuming minimal impact.  
Nonetheless, to ensure robustness, two Moran's I calculations were performed:  
1. Including all points, even those disconnected.
2. Excluding the disconnected points and using only effective spatial relationships.  
The results were as follows:  
As shown in Table 6, Moran's I (I \(\approx\) 0.5177) and \(p\)-value = 0.001 in both cases confirm a strong spatial autocorrelation. The slight variation in Z-scores (2663.38 vs. 2714.04) indicates that excluding disconnected points does not substantially alter the analysis. Hence, the observed spatial patterns in waiting times are not random; there are statistically significant clusters of similar values.  
The high positive value of I indicates that areas with long waiting times are often surrounded by other areas that also experience lengthy waits (and vice versa for short  
\begin{table}
\begin{tabular}{c c c} \hline \hline
**Metric** & **Including All Points** & **Excluding Disconnected Points** \\ \hline Moran’s I & 0.5177 & 0.5177 \\ \(p\)-value & 0.001 & 0.001 \\ Z-score & 2663.38 & 2714.04 \\ \hline \hline \end{tabular}
\end{table}
Table 6: Moran index results.  
Figure 5: Heatmap of waiting times in Greater Valparasio.  
waits), suggesting geographic or urban planning factors that influence transport efficiency. Since this strong spatial autocorrelation revealed inequalities in critical areas, the next step involved applying a clustering analysis to pinpoint these groupings more accurately, facilitating targeted interventions to improve service.