## 3 Results and Discussion
### Effect of the Number of Weeks of Data on the Population Predictor  
So far, it has been observed that using population data to train local models does not jeopardize prediction accuracy when applied to an individual, compared to training with individual data and assuming the same individual dataset size. Now, the effect of the data size (in number of weeks of data used to train the local models) on the predictions \(\hat{G}_{\mathcal{M}}(i)\), \(\hat{G}_{\mathcal{N}}(i)\), and \(\hat{G}_{\mathcal{H}}(i)\) is analysed. The initial hypothesis was that, as the size of the training dataset is reduced, so is the predictive power of the ensemble of models that comprise the global predictors. To confirm this hypothesis, we evaluate the performance of the predictors \begin{table}
\begin{tabular}{c c c c} \hline  & \begin{tabular}{c} **Number of** \\ **Predictions** \\ \end{tabular} & \
\begin{tabular}{c} **RMSE** \\ **Individual** \\ **(mg/dL)** \\ \end{tabular} &
\begin{tabular}{c} **RMSE** \\ **Population** \\ **(mg/dL)** \\ \end{tabular} \\ \hline \multicolumn{4}{c}{**PH = 180 min**} \\ \hline Meals & 74,297 & 32.14(6.80) & 34.92 (6.70) \\  & 30.31 [27.52, 34.38] & 33.21 [31.40, 35.45]\(\bullet\) \\ \hline Night & 7182 & 13.25 (4.41) & 14.89 (5.96) \\  & 13.32 [9.33, 14.79] & 13.38 [11.63, 16.20] \\ \hline Hypo & 374 & 41.50 (25.48) & 48.39 (15.44) \\  & 35.28 [29.39, 41.73] & 45.89 [39.24, 59.79] \\ \hline Overall & 81,853 & 28.96 (19.10) & 32.73 (17.17) \\  & 28.45 [14.79, 34.38] & 32.30 [16.20, 41.59]\(\bullet\) \\ \hline \multicolumn{4}{c}{**PH = 240 min**} \\ \hline Meals & 53,118 & 34.53 (9.29) & 33.28 (7.43) \\  & 33.93 [27.40, 37.77] & 31.02 [28.80, 35.09] \\ \hline Night & 1384 & 12.87 (6.05) & 15.10 (7.23) \\  & 10.38 [8.30, 16.19] & 13.72 [9.35, 17.36] \\ \hline Hypo & 117 & 41.58 (14.18) & 55.26 (20.57) \\  & 43.77 [30.66, 50.34] & 63.35 [47.86, 65.74] \\ \hline Overall & 54,619 & 27.28 (15.18) & 30.40 (18.45) \\  & 25.58 [13.10, 36.60] & 28.80 [15.13, 37.18] \\ \hline \end{tabular}
\end{table} 
Table 2: Cont. using population sets of \(\{2,4,6,8,12,16\}\) weeks of data in \(\Pi_{\mathcal{M}},\Pi_{\mathcal{N}},\Pi_{\mathcal{H}}\), and prediction horizons ranging \(PH\in\{15,30,60,120,180,240\}\) min. The number of clusters for each partition predictor was calculated for each set of identification data (from 16 to 2 weeks) using the FS index (see Section 2.4, and results are reported in Table 1). As can be seen in Table 1, the ideal number of clusters is lower in scenarios for smaller numbers of weeks, which is expected since the volume of data is lower. This behaviour affects particularly to the number of clusters in the Night and Hypoglycemia predictor, since the number of these events decrease drastically in smaller datasets. The same validation procedure followed in Section 3.1 was used here to compare the predictive power of the different glucose predictors when trained with different population data volumes. Figure 3 shows the distribution of the prediction error (RMSE median and quartiles) vs the different training dataset sizes for all the prediction horizons. For all considered PHs, the hypoglycemia glucose predictor is clearly the most erratic (larger error bars) and on average, the one that shows higher median errors. It can also be observed that for low PHs (\(PH\in\{15,30,60\}\)) no significant difference is observable in the RMSE, except for an abnormally high error when only 2 weeks of data were used for training. For higher PHs (\(PH\in\{120,180,240\}\)), the RMSE remains almost constant when training with 4, 6, 8 or 12 weeks of data, but is worse for 2 or 16 weeks, suggesting a \"sweet spot\" of training data volume between 4 and 12 weeks of data. The most plausible explanation for this phenomenon is a tendency of over-fitting anomalous or highly variable behaviors in the scenario with 16 weeks of data, and a lack of relevant dynamics in the 2 weeks of data.