import geopandas as gpd
from shapely.geometry import Point
stores = gpd.read_file('stores.geojson').to_crs(epsg=3857)
customers = gpd.GeoDataFrame(
customer_df,
geometry=[Point(xy) for xy in zip(customer_df.longitude, customer_df.latitude)],
crs='EPSG:4326',
).to_crs(epsg=3857)
nearest_store = gpd.sjoin_nearest(customers, stores[['store_id', 'geometry']], how='left', distance_col='distance_meters')
print(nearest_store[['customer_id', 'store_id', 'distance_meters']].head())
Location data becomes useful when spatial joins and distance-based features are handled correctly. GeoPandas is enough for many routing, service coverage, and market analysis tasks before you need heavier GIS infrastructure. I care about coordinate systems first because almost every mistake starts there.