carto-spatial-autocorrelation

Installation
SKILL.md

Spatial Autocorrelation with Moran's I

Builds CARTO Workflows that measure spatial autocorrelation using Moran's I, determining whether a variable exhibits clustering, dispersion, or randomness, and classifying each location into HH/HL/LH/LL quadrants.

Prerequisites: Load carto-create-workflow for the development process, JSON structure, and validation commands.

When to use Moran's I vs Getis-Ord Gi*:

  • Moran's I: "Is there clustering?" + classify into cluster types (HH, HL, LH, LL) + identify spatial outliers (HL, LH)
  • Getis-Ord Gi*: "Where are the hotspots/coldspots?" + magnitude of clustering (z-scores)

Instructions

A Moran's I workflow follows this pipeline:

Source Data -> (Filter) -> Spatial Indexing (H3) -> Aggregation -> Moran's I -> (Filter Significant) -> Save
Installs
26
GitHub Stars
3
First Seen
May 15, 2026
carto-spatial-autocorrelation — cartodb/agent-skills