Skip to content
  • Posts
  • Join the Spatial Lab
  • Learn Modern GIS
  • Sponsor
  • Coaching
  • Podcast

Get the newsletter

Join 71,000+ geospatial experts growing their skills and careers. Get updates on the most cutting edge updates in modern GIS and geospatial every week.

  • LinkedIn
  • YouTube
Uncategorized

Get started with Python and GeoPandas in 3 minutes

December 7, 2021 Matt Forrest Comments Off on Get started with Python and GeoPandas in 3 minutes

Looking to get started with geospatial Python and GeoPandas! Below you can find the step-by-step instructions to go along with the following video to get you up and running with GeoPandas in no time at all.

First, open Google Colab

Google Colab

First, head over to Google Colab and get started by creating a new notebook. Google Colab is a free service from Google that provides a hosted notebook interface for Python that has some libraries pre-installed. It is one of the fastest ways to get started with Python in a notebook interface!

Install and Import GeoPandas

In the first cell of the notebook, you can install GeoPandas using pip. Normally, you would use pip on the machine or server where you have Python installed, but in the notebook, you can install it in a normal cell using this command:

pip install geopandas

Next, you can import the library and give it a shorthand name in the next cell:

import geopandas as gpd

Read a file and plot the map

Next, you can download some data (the data I used in the video can be found here) and read the file using the read_file() command. You can then plot a very simple map using the plot() function. This is a super simple map with no frills, but after this, you have just installed and started using GeoPandas!

Read and plot data

Filter the data and make a map

If you are following along in the video, I show a few different techniques for filtering your data by filtering rows as well as using the isin() function from Pandas. You can check out the Pandas Cheat Sheet and the Pandas Cookbook for more details, in addition to the Pandas docs.

I also created a small buffer around the state of Rhode Island which you can find more information on in the GeoPandas docs.

Try it yourself!

Next, test out some of the guides from the GeoPandas User Guide, Getting Started, and Examples Gallery! You can also check out some other geospatial Python resources in my guide below.

75+ Geospatial Python and Spatial Data Science Resources and Guides
  • Python
Matt Forrest

Post navigation

Previous
Next

Search

Categories

  • Article (29)
  • Essay (1)
  • Podcast (5)
  • Tutorial (7)

Recent posts

  • Convert a Shapefile to GeoParquet (Python, DuckDB, Sedona)
    Convert a Shapefile to GeoParquet (Python, DuckDB, Sedona)
  • I Gave Claude AI Full Control of QGIS: What Happened
    I Gave Claude AI Full Control of QGIS: What Happened
  • AI for GIS: 5 Prompts That Replace Hours of Work
    AI for GIS: 5 Prompts That Replace Hours of Work

Tags

aggregations Apache Airflow Apache Iceberg Apache Sedona ArcGIS bigquery Cloud-Native Geospatial Cloud GIS Cloud Optimized GeoTIFF duckdb Esri geoparquet geospatial gis GISP Modern GIS postgis Python snowflake Spatial SQL sql Wherobots zip codes

Related posts

Convert a Shapefile to GeoParquet (Python, DuckDB, Sedona)
Tutorial

Convert a Shapefile to GeoParquet (Python, DuckDB, Sedona)

October 28, 2026 Matt Forrest Comments Off on Convert a Shapefile to GeoParquet (Python, DuckDB, Sedona)

I took a real Shapefile with almost 1.1 million polygons and converted it to GeoParquet three different ways. The file went from over 1.4 GB of source data down to 246 MB, opened cleanly in QGIS, and ran spatial queries in seconds instead of minutes. The dataset was the New York City building footprints. Every […]

Article

The 37 Geospatial Python Packages You Definitely Need

January 3, 2024 Matt Forrest Comments Off on The 37 Geospatial Python Packages You Definitely Need

When performing geospatial analysis, the right set of tools can be the difference between surface-level insights and deep, actionable intelligence. Fortunately, amazing geospatial Python packages help to bridge this gap. Python, renowned for its versatility and robustness, offers a wide range of packages that can not only help you scale your spatial analysis, but reach […]

Learn geospatial Python
Uncategorized

Learn Geospatial Python with these top courses

October 26, 2022 Matt Forrest Comments Off on Learn Geospatial Python with these top courses

Python is fast becoming one of the top languages for data analysis and data science, and for good reason. It is quick to learn, can be used for many use cases, and is fast becoming a key skill for job seekers. Python for GIS and geospatial analysis is no different. It can help you scale […]

Spatial Lab
  • Join the Spatial Lab community
Policies
  • Privacy Policy
  • Terms & Conditions
  • Refund Policy
  • Cookie Policy
Spatial SQL
  • Get the Spatial SQL book today
Join Us

© Matt Forrest 2024. All Rights Reserved.

Manage Consent
To provide the best experiences, we use technologies like cookies to store and/or access device information. Consenting to these technologies will allow us to process data such as browsing behavior or unique IDs on this site. Not consenting or withdrawing consent, may adversely affect certain features and functions.
Functional Always active
The technical storage or access is strictly necessary for the legitimate purpose of enabling the use of a specific service explicitly requested by the subscriber or user, or for the sole purpose of carrying out the transmission of a communication over an electronic communications network.
Preferences
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
Statistics
The technical storage or access that is used exclusively for statistical purposes. The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
Marketing
The technical storage or access is required to create user profiles to send advertising, or to track the user on a website or across several websites for similar marketing purposes.
  • Manage options
  • Manage services
  • Manage {vendor_count} vendors
  • Read more about these purposes
View preferences
  • {title}
  • {title}
  • {title}