Spatial Statistics — a free, interactive course
Learn spatial statistics by writing and running real Python in your browser. There is nothing to install: NumPy, pandas, SciPy and Matplotlib run inside the page via Pyodide (WebAssembly), and every dataset is fetched live from open repositories. Each lesson breaks the method into small steps, gives you a worked example, then asks you to write the key line yourself and checks your answer. Created by Eric Vaz, Full Professor of Geography and Environmental Studies at Toronto Metropolitan University.
What you will learn
Spatial autocorrelation and Moran's I (in Python)
Build a spatial weights matrix with k-nearest neighbours, row-standardise it, and form the spatial lag. Code Moran's I from scratch, test it with a permutation test, and read a Moran scatterplot. Understand spatial autocorrelation, the idea that near things are more related than distant things, on real US population-density data.
LISA and hot-spot analysis
Compute Local Moran's I (LISA, Anselin 1995), classify each area into HH, LL, HL and LH quadrants, assess significance with a conditional permutation test, and draw a LISA cluster map of statistically significant hot spots and cold spots.
Interpolation, variograms and kriging
Fit first- and second-order trend surfaces by least squares, compute an empirical semivariogram and fit a spherical model (nugget, sill, range), then solve the ordinary kriging system to predict values at unsampled locations with a map of kriging variance (uncertainty).
How it works
Free and open. Progressive modules. Live Python in the browser. Real, open data over CORS-enabled CDNs. Progress is saved only in your browser. Topics include spatial weights, the spatial lag operator, global and local indicators of spatial association, point and areal data, choropleth mapping, geostatistics and spatial prediction.
About the author
Eric Vaz is a Full Professor of Geography and Environmental Studies at Toronto Metropolitan University working in spatial analysis, regional science and GeoAI. See his Google Scholar profile for peer-reviewed applications of these methods, and the Geography of Opportunity podcast.