4.1. Comparing GPP-GAM and MGWR
The comparisons of the estimated coefficients with the true coefficients arising from the 100 GGP-GAM and MGWR models are shown in
Figure 5. The boxplots have the outliers removed to emphasise the differences between the median values in the fit measures. For each fit measure (RMSE, MAE, R
2), the GPP-GAM provides more accurate estimates of the true coefficients than MGWR, with the accuracy difference increasing with the degree of spatial heterogeneity (i.e. from
to
).
The distributions of model fit indicated by AIC show that the GGP-GAMs consistently have lower AIC values compared to the MGWR models. Investigations of the large differences in AIC values revealed them to be driven by differences in the residuals, rather than the number of model parameters. These are summarised in
Table 1.
The spatial variation in the residuals was also compared. A Moran’s I statistic was generated for the residuals arising from each GGP-GAM and MGWR model. Their distributions are summarised in
Table 2. The MGWR residuals have higher positive values indicating stronger positive spatial autocorrelation (i.e. clustering), while the GGP-GAM residuals have more negative values indicating stronger negative spatial autocorrelation (i.e. dispersion).
The accuracy of the predicted measures of
y (i.e.
) arising from the two models are compared in
Figure 6, using RMSE, MAE and R
2. The GGP-GAMs generate more accurate predictions, reflecting their better of estimation of the true coefficients.
Model calibration can be investigated. The GGP-GAM spline smoothing parameters are part of a covariance function that penalizes model complexity, while the covariate-specific bandwidths in MGWR describe the scale of each predictor-to-response relationship, thereby reflecting the scale of process spatial heterogeneity. These are summarised in
Table 3. The homogeneity of these, as indicated by the inter-quartile ranges, reflect the convergence of the bandwidth optimisation in the MGWR models and the optimisation of the spline smoothing parameters in the GGP-GAM models.
4.2. A Single GGP-GAM in Detail
It is instructive to examine the nature of a GGP-GAM and its coefficients in detail. The 51st model was randomly selected and its properties examined. Diagnostics summaries of the model SVCs are shown in
Table 4. These are generated by the
gam.check function in the
mgcv package, summarise the results of the model optimisation procedures and allow the basis dimensions defined by
k to be evaluated. Wood [
24] notes that a “
low p-value and a k-index of ) may indicate that k is too low, especially if effective degrees of freedom (EDF) are close to k”. Similar results were found for other models that were investigated. It is evident that for these models, a
k value of 155 is adequate: the EDFs are lower than
k and all the p-values are high.
It is also possible to examine the fixed (parametric) coefficient estimates. These can be considered as the linear model terms, similar to the outputs of a standard OLS regression and are shown in
Table 5. The effect of the large
k is evident: the Intercept has a significant global effect and the global relationships between the response and the covariates are reduced to zero.
Table 6 summarises the smooth terms, the geographic GP splines (for each SVC). The full set of coefficients are not printed because there many coefficients for each spline, one for each basis function. The
edf (effective degrees of freedom) indicates the spline complexity, with higher
edf values indicating increasing non-linearity in the predictor-to-response relationship. For example, an
edf of 1 suggests a linear relationship, an
edf of 2 a quadratic one, etc. In this context, these values apply to each covariate across a 2-dimensional space defined by
, and the p-values indicate the significance of any spatial variation in the coefficient estimates - i.e. whether they vary significantly over space. In this case the SVCs for
,
and
are locally significant but the Intercept (
) is not.
It also is possible to examine whether and how the relationships between
y and the covariates vary spatially - i.e. the SVCs.
Table 7 summarises these for the single GGP-GAM model. These reflect the relatively low spatial variation in the Intercept and its globally significant effect, and the relatively high spatial variation in the coefficient estimates for
,
and
.
A final investigation maps the estimated GGP-GAM and MGWR SVCs. These are shown for the 51st GGP-GAM and MGWR models in
Figure 7 alongside the true coefficients. The GGP-GAM and MGWR coefficients are estimated from the same input data, and the shading range was intentionally set to the same as
Figure 1. The estimated coefficient surfaces for
,
,
and
indicate better performance the GAM based approach over MGWR. The grey areas in the MGWR coefficient estimates indicate predicted values outside of range of -2.2 to +2.2.
4.3. GGP-GAM Tuning with a Larger Dataset
A second set of analyses investigated the impact of increased observation number and tuning via the knots parameter for 250,000 observations over a 500 by 500 grid (
Figure 2. A single set of simulated predictors
,
and
were again calculated from random normal distributions rescaled to have a range of [0, 1] with a random normally distributed error term
rescaled to [0, 0.25]. The response variable
y was calculated directly from these and the coefficients in
Figure 2. Seven GGP-GAM models were constructed but specified with different vales of
k: 100, 250, 500, 750, 1000, 1500 and 2000. The evaluations included computation time, coefficient accuracy and predictive performance.
Model characteristics and model fits are shown in
Figure 6. Model deviance (unpenalized), the effective model residual degrees of freedom and the estimated variance parameter all decrease with increased
k as might be expected. The model fits also increase with as the degree of tuning increases with
k. There is a distinct elbow to many of these trends suggesting suggests that a trade-off is possible between more complex models and increased computation times with higher values of
k.
Figure 8.
The GGP-GAM model metrics and fits with increasing number of knots k.
Figure 8.
The GGP-GAM model metrics and fits with increasing number of knots k.
Table 8 summarises the residuals arising from the different GGP-GAMs. They have similar central tendencies and the inter-quartile ranges indicates that although the models with higher values of
k have a lower variation, the differences are not dramatic. Again this reinforces the possibility of a model complexity trade-off with accuracy.
The fixed parametric coefficient estimates of the seven different models were investigated to examine the degree to which the effects observed in
Table 5 for the small single GGP-GAM model are also found (i.e. a significant intercept and insignificant covariates whose coefficients were zero). These are shown for models constructed from the larger dataset in
Table 9. Whilst the intercept (
) has a similar value for each model and is always significant, the trend in the other covariates is more variable, especially at lower values of
k. However, they are not significant for the models when
.
Table 10 summarises the smooth terms for the seven models, the geographic GP splines. Recall that the effective degrees of freedom (
edf) summarises the complexity of the spline smooths and that p-values indicate whether the coefficients are locally significant and whether their respective covariate relationship with the target variable
y varies locally. In the model constructed for the single smaller dataset summarised in
Table 6, the spatially varying intercept was not significant locally, but all the other covariates were. The same pattern is found with the larger data, but notice how the effective degrees of freedom increases with
k.
The GGP-GAM spline smoothing parameters from the different models were examined. Recall that the homogeneity of these indicate the convergence of the models as determined by
k which define the spline basis dimensions. These are summarised in
Table 11 for the different models. Two trends are evident in the smoothing parameter values across all values of
k: the heterogeneity of the Intercept across the different values of
k, reflecting its global significance and and local in-significance, in
Table 9 and
Table 10 respectively, and the homogeneity within each covariate, with values of the same order of magnitude across values of
k.
In summary, series of GGP-GAMs were constructed using a larger simulated dataset, with different values of
k. As
k increases the number of spline bases increase and the models take longer to fit, indicating the trade-off between model complexity and computation time. A distinct elbow was found with increasing
k in model deviance, residual degrees of freedom, and estimated variance as well as in the model fit measures (AIC, R
2, RMSE, MAE) suggesting possible trade-offs at around
to
(
Figure 6). The residuals of this model were found to be similar to those of the models with high values of
k (
Table 8), where greater tuning might be expected to result in stronger model performance. Except for the Intercept, the global parametric coefficients flatten out or are insignificant at all values of
k (
Table 9) and all the covariates are locally significant at all values of
k (
Table 10), supporting trade-offs at values of
k between 500 and 750 in this case.
4.4. Empirical Example: Brexit Vote
A final empirical analysis compared GGP-GAM and MGWR SVC models of the 2016 UK referendum on leaving the EU in England, Wales and Scotland (
Figure 4). The model summaries are shown in
Table 12 and in this case both models perform well in terms of fit metrics (R
2, AIC, MAE, RMSE) with the MGWR model marginally out-performing the GGP-GAM model, and the GGP-GAM model running more efficiently. However perhaps of greater interest are the minor differences in coefficient estimates as summarised in
Table 13 and
Table 14 and mapped in
Figure 9. The tables include diagnostic metrics of the significance of the GGP-GAM local coefficients and the MGWR bandwidths whose size indicate the degree of localness (their theoretical maximum is 1198 km).
Overall, when the central tendencies and inter-quartile ranges are examined, both sets of coefficient estimates have similar values and ranges. Considering each in turn, a number of observations can be made:
Intercept (): This is not locally significant in the GGP-GAM model but is in its parametric form (not shown). The MGWR model indicates that it has a highly localised (i.e. spatially varying) relationship with a relatively small bandwidth. Both sets of coefficient estimates are positive and have similar values and ranges.
Christian: Both sets of coefficient estimates indicate a negative association with the Leave vote in Scotland and parts of North Wales and a positive one in England. It is locally significant in the GGP-GAM model and exhibits moderate local variation in the MGWR model, with a bandwidth of 159 km.
Degree: This is locally significant in the GGP-GAM model and is negatively associated with the Leave vote throughout the study area in both models. It indicates moderate local variation in the MGWR bandwidth (204 km).
No Car: This is locally significant in the GGP-GAM model. It is mostly negatively associated with the Leave vote share in both models and indicates similar areas of positive association with the Leave vote share in the North. The MGWR bandwidth indicates moderate local variation (172 km).
Younger: This is not locally significant in the GGP-GAM model In the MGWR, its bandwidth (1196 km) indicates that it is globally (evenly) associated with the Leave vote share.
In summary the two models have similarly high fit and accuracy metrics but they suggest subtly different process spatial heterogeneities and non-stationarities in the relationships between the Brexit Leave vote share as the target variable and the different predictor variables. These are more apparent in the extremes of the study area, potentially reflecting the mechanics of the moving window approach in GWR-based models.