Skip to main content

Python Path: Geospatial Python for Social Scientists

38 modules

About

This course is a guided route through the Spatial Turn training in Python. It starts with no programming background and ends with network analysis, spatial statistics and two complete case studies, all in Jupyter notebooks that run in the SpatialTurn GIS kernel on CyberFaCES (no installation needed). It is written for social scientists and other researchers who want to add maps and spatial analysis to their work.

The path has 9 stages and 38 modules, about 43 hours in all. The modules are the same ones that make up the eight Spatial Turn courses. Take the stages in order; within a stage, the modules build on each other.

Stage Modules Time
1. Start here Introduction to Foundations; Python Basics; Working with Data; Geospatial Python Basics; Map Your County in Python 7.4 h
2. Know your data Introduction to Data Management; Geospatial Data Models; Geospatial File Formats; Coordinate Reference Systems; Designing Your Data; Organizing, Versioning and Backing Up; Data Quality 5.2 h
3. Find and collect data Introduction to Data Collection; Data from the U.S. Census Bureau; Geocoding and Adding Spatial Context; Collecting Data in the Field 3.5 h
4. Prepare and process data Introduction to Data Processing; Cleaning and Preparing Data in Python; Geoprocessing in Python; Raster Processing in Python; Automating Repeated Steps in Python 5.9 h
5. Make finished maps Introduction to Data Visualization; Cartography Checklists; Fundamentals of Map Design; Cartography in Python; Accessibility in Map Design 7.2 h
6. First case study Park Access in Lafayette (Python) 1.2 h
7. Advanced methods Network Analysis; Spatial Autocorrelation with PySAL; Spatial Clustering; NDVI Analysis 5.7 h
8. Advanced case study Case Study: Food Deserts 1.8 h
9. Share your data Introduction to Data Curation; Metadata; Documentation; Preservation; Sharing and Publishing Data; Ethics and Sensitive Location Data 4.7 h

Prefer QGIS? The QGIS Path covers the same ground with QGIS. Every module also belongs to one of the eight Spatial Turn courses (Foundations, Data Management, Data Collection, Data Processing, Data Visualization, Data Analysis, Case Studies and Data Curation), if you would rather follow a single topic.

This course is part of Enabling the Geospatial Turn in the Social Sciences, a set of training modules developed at Purdue University with support from the National Science Foundation.

Features
Type Course
Level Foundation
Length 1 day
Topics python
Community: Spatial Turn

Modules

  • Introduction to Foundations

    Module 1 • 30 minutes

    The other modules in this curriculum assume a little background: how to run a Python notebook, what a table and a map layer are, and how to load data into QGIS. This module teaches exactly that, from zero. If you have never written code or opened a GIS, start here.

  • Python Basics

    Module 2 • 2 hours

    Running cells, variables, text, lists, dictionaries, decisions, loops and functions. Six short notebooks, each covering one idea and ending with an exercise and its solution; the examples use Indiana counties.

  • Working with Data

    Module 3 • 1 hour

    Tables with pandas and charts with matplotlib.

  • Geospatial Python Basics

    Module 4 • 2 hours

    Map layers with GeoPandas, coordinate reference systems, attribute and spatial joins, and rasters with rasterio.

  • Map Your County in Python

    Module 5 • 1 hour

    Capstone: a Census table to a finished, shareable map. A local food bank wants a one-page map of where households without a car live in Tippecanoe County, Indiana, to plan a delivery service. You will deliver it as a PNG image that a reader with no GIS experience can understand.

  • Introduction to Data Management

    Module 6 • 40 minutes

    The research data lifecycle, why geospatial data needs extra care, and data management plans

  • Geospatial Data Models

    Module 7 • 45 minutes

    Vector and raster data, topology, resolution, and choosing a representation

  • Geospatial File Formats

    Module 8 • 45 minutes

    Shapefile, GeoPackage, GeoJSON, GeoTIFF and others, and which to use when

  • Coordinate Reference Systems

    Module 9 • 45 minutes

    Datums, geographic and projected systems, EPSG codes, and defining versus reprojecting

  • Designing Your Data

    Module 10 • 50 minutes

    Data dictionaries, field types, domains, unique IDs and relationships

  • Organizing, Versioning and Backing Up

    Module 11 • 45 minutes

    Folder structures, file names, portable projects, version control and the 3-2-1 rule

  • Data Quality

    Module 12 • 45 minutes

    Elements of spatial data quality, geometry errors, and quality checks

  • Introduction to Data Collection

    Module 13 • 35 minutes

    When to use existing data or collect your own; vector and raster data; judging data quality; FAIR data

  • Data from the U.S. Census Bureau

    Module 14 • 1 hour

    Census geography, the Decennial Census and the ACS, margins of error, and the Census API

  • Geocoding and Adding Spatial Context

    Module 15 • 1 hour

    Turning addresses into points, checking match rates, and downloading features from OpenStreetMap

  • Collecting Data in the Field

    Module 16 • 40 minutes

    Methods and apps, designing a schema, GPS accuracy, ethics and quality checks

  • Introduction to Data Processing

    Module 17 • 35 minutes

    What happens between download and analysis, and how to keep processing repeatable

  • Cleaning and Preparing Data in Python

    Module 18 • 1 hour

    Fix identifiers, types, special codes, duplicates and geometry problems with pandas and GeoPandas

  • Geoprocessing in Python

    Module 19 • 1 hour

    Buffers, selecting by location, clip, intersect, dissolve, areal weighting and nearest features in GeoPandas

  • Raster Processing in Python

    Module 20 • 1 hour

    Map algebra, reclassification and zonal statistics with rasterio and rasterstats

  • Automating Repeated Steps in Python

    Module 21 • 1 hour

    Functions and loops that run one workflow for many distances, layers and counties

  • Introduction to Data Visualization

    Module 22 • 1 hour

    Why we visualize, how charts mislead, and design principles that apply to every figure

  • Cartography Checklists

    Module 23 • 1 hour

    The questions to answer before making any map: audience, message, data, medium

  • Fundamentals of Map Design

    Module 24 • 1 hour

    Map elements, color schemes, projections, thematic map types, normalization and classification

  • Cartography in Python

    Module 25 • 1 hour

    Finished maps in Python: layer order, labels with halos, basemaps, locator insets, scale bars, small multiples and export

  • Accessibility in Map Design

    Module 26 • 1 hour

    Designing maps for people with color vision deficiency, testing palettes and writing alt text

  • Park Access in Lafayette (Python)

    Module 27 • 1 hour

    Who can walk to a public park in Lafayette and West Lafayette, and are children and households without a car as well served? In Python

  • Network Analysis

    Module 28 • 1 hour

    How far is it by road, and how long does it take? Road networks, shortest paths and travel time with osmnx and networkx

  • Spatial Autocorrelation with PySAL

    Module 29 • 1 hour

    Are similar values clustered, and where? Spatial weights, global and local Moran's I with libpysal, esda and splot

  • Spatial Clustering

    Module 30 • 1 hour

    Where do points concentrate into hotspots? DBSCAN, HDBSCAN and K-Means on Chicago crime points

  • NDVI Analysis

    Module 31 • 1 hour

    How green is the landscape in a satellite image? NDVI from Landsat, classification and machine learning

  • Case Study: Food Deserts

    Module 32 • 1 hour

    Where do people have low income and live far from a supermarket? Map the USDA Atlas, then rebuild its analysis from open data

  • Introduction to Data Curation

    Module 33 • 40 minutes

    What curation is, the curation lifecycle, public access policies and the FAIR principles

  • Metadata

    Module 34 • 50 minutes

    Kinds of metadata, essential geospatial elements, and standards such as ISO 19115, DataCite and DDI

  • Documentation

    Module 35 • 45 minutes

    README files, codebooks, provenance, and citing data

  • Preservation

    Module 36 • 45 minutes

    Durable formats, checksums, the OAIS model, trustworthy repositories and very large data

  • Sharing and Publishing Data

    Module 37 • 50 minutes

    Choosing a repository, DOIs, licenses, access levels, and the FAIR and CARE principles

  • Ethics and Sensitive Location Data

    Module 38 • 50 minutes

    Re-identification, aggregation and geomasking, sensitive places, consent and review

Instructor

Aniket Dev Roy avatar

Aniket Dev Roy

61 modules

Discussions

Please login to view discussions.

Reviews

- Not reviewed yet
  • 5 stars
    0%
  • 4 stars
    0%
  • 3 stars
    0%
  • 2 stars
    0%
  • 1 star
    0%
No reviews yet.