spatial-statistics

Solid

Always invoke before testing a geographic pattern for clustering, hotspots, dependence, or explanatory regression, even when aggregation or ordinary OLS is proposed as routine. Covers Moran's I, LISA, Getis-Ord Gi*, weights, MAUP and scale sensitivity for areas/grids, residual dependence, and spatial lag/error/GWR/MGWR models. Use ML standards for predictive evaluation and geostatistics for continuous surfaces from sparse samples.

AI & Automation 3 stars 0 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 79/100

Stars 20%
20
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
80
License 10%
100
Description 5%
100

Skill Content

# Spatial Statistics Purpose: answer "is it clustered, where, and why" with defensible inference. The core discipline: spatial data violates independence assumptions, so standard statistics silently overstate significance — every analysis here starts with weights design and ends with residual diagnostics. ## Spatial weights (W) — the analysis IS the weights Every result downstream depends on W; choose it for substantive reasons and run a sensitivity check with one alternative: | Weights | Use when | |---|---| | Queen/Rook contiguity | Irregular polygons (admin units, parcels) | | K-nearest neighbors | Points; islands present (contiguity leaves them unconnected) | | Distance band | Physical process with known range | | Kernel (distance-decayed) | Smooth influence, GWR-style local models | ```python from libpysal.weights import Queen w = Queen.from_dataframe(gdf, use_index=True) print(f"islands: {w.islands}") # unconnected units break stats — fix or document w.transform = "r" # row-standardize (default for Moran/lag models) ``` Always report: weights type, parameters, number of islands, and whether results survive an alternative W. ## Global → local workflow 1. **Global Moran's I** (`esda.Moran`, permutation inference ≥999) — answers "any clustering at all?" Report I, p_sim, and the permutation distribution, not the analytical p. 2. **LISA / local Moran** (`esda.Moran_Local`) — maps WHERE: High-High, Low-Low clusters, High-Low/Low-High outlier...

Details

Author
muend
Repository
muend/geoai-skills
Created
1 weeks ago
Last Updated
yesterday
Language
Python
License
MIT

Similar Skills

Semantically similar based on skill content — not just same category

AI & Automation Solid

geostatistics-interpolation

Turn scattered point measurements into continuous surfaces with quantified uncertainty: variogram modeling, ordinary/universal/regression kriging, IDW, and spatially honest cross-validation. Use when unobserved values must be estimated from sparse samples such as stations, wells, or soundings. Trigger on "interpolate", "kriging", "variogram", or "IDW"; a named interpolation method is sufficient even when the requested surface is described informally as a heatmap. Do not use for point-density heatmaps, zonal aggregation, or raster resampling without value interpolation.

3 Updated yesterday
muend
AI & Automation Solid

geographer

Geographic lens for product, market, and operational analysis. Applies spatial reasoning, GIS and remote-sensing literacy, regional differentiation, place-based analysis, scale awareness, and cartographic discipline to problems of market sizing, supply-chain mapping, regulatory jurisdiction overlays, climate-risk geography, and catchment-area delineation. Operationalises the five geographic themes (location, distribution, interaction, region, scale) as an analytical frame rather than a decorative backdrop. Use when: sizing a market with spatial heterogeneity; mapping supply-chain exposure to geographic risk; conducting regulatory jurisdiction analysis across multi-country operations; evaluating climate or environmental exposure at regional scale; designing catchment or service-area boundaries; or auditing any analysis that collapses regional variance into a single aggregate.

3 Updated today
Canhada-Labs
AI & Automation Solid

cartography-geoviz

Always invoke before answering any request to create, compare, design, or review a user-facing map, even if the request is terse or underspecified. Covers publication maps, choropleths, map series and small multiples, comparable multi-date panels, proportional/bivariate/flow maps, raster rendering, and interactive web maps. Includes classification, color, legends, projections, accessibility, and large-data aggregation. Do not trigger for a temporary diagnostic plot inside another analysis.

3 Updated yesterday
muend