Haiyang LIU; Yongze SONG; Wen YI
2026/01/22
Liu, H., Song, Y., & Yi, W. (2026). Degree of spatial interpretability. International Journal of Geographical Information Science, 1–21. https://doi.org/10.1080/13658816.2026.2614335
The demo dataset is derived from the Australia case study in this paper and is consistent with the input data used to compute the DSI metrics in the manuscript. It covers the Australian continent at a 0.5° × 0.5° grid (sampling-point) resolution; each row represents one grid cell/point and includes geographic coordinates (WGS84), the response variable y (richness in the paper), and the same set of environmental, topographic, and soil predictors (X) as reported in the study. The residual column was generated from the paper’s linear regression model (lm) by predicting on the held-out test set after the train/test split and computing residuals as y − ŷ. The file provided in this repository is the standardized test-set input (lon/lat/y/residual/all X) intended to reproduce the paper’s Moran’s I and Q value calculations, and thus derive θmin, θprobable, and θmax.
Your CSV must include these columns (recommended to use exactly these names):
lon: longitudelat: latitudey: dependent variableresidual: a single column of model residuals (computed by you)
All other columns will be treated as X variables (used for Q-value stratification).
infile: path to your CSV fileprojected_crs: a projected CRS in meters- Australia:
3577 - Other regions: use an appropriate local UTM zone or a national equal-area projection (must be in meters)
- Australia:
k_neighbors: KNN neighbor number for Moran’s I- Dense samples:
6–10 - Sparse samples:
10–20
- Dense samples:
alternative: hypothesis for Moran’s I test- Common choice:
"greater"(tests for positive spatial autocorrelation)
- Common choice:
The script prints 7 metrics:
δ0a: Moran’s I ofyδra: Moran’s I ofresidualδ0h: Q value ofy(via GD)δrh: Q value ofresidual(via GD)θmin = min(ηa, ηh)θprobable = max(ηa, ηh)θmax = 1 − (1−ηa)(1−ηh)
-
Error: “not enough points for KNN”
You have too few samples ork_neighborsis too large. Reducek_neighbors. -
Unreasonable results due to CRS
Make sureprojected_crsis a projected coordinate system in meters. Do not useEPSG:4326(degrees) to build distance-based neighbors.