I am trying to plot latitude and longitude coordinates on a contextily basemap but thus far have been unable to do so because the "inferred zoom level is not valid for the tile provider." enter image description here

df1 = pd.DataFrame(clip_businesses)

geometry1 = [Point(xy) for xy in zip(df1['Long'], df1['Lat'])]
gdflittleton = gpd.GeoDataFrame(df1, geometry=geometry1)

gdflittleton_web_mercator = gdflittleton.to_crs(epsg=3857)

# Create subplots
fig, ax = plt.subplots(1, 1, figsize = (10, 10))

gdflittleton_web_mercator.plot(ax = ax, marker = 'o', color = 'dodgerblue', markersize = 3)

ctx.add_basemap(ax, crs='EPSG:3857', source=ctx.providers.CartoDB.Voyager)

Even when I manually change the zoom level for the contextily map, I still am left with a blank slate. In short, I'm hoping to plot lat long coordinates over a contextily basemap.

0

There are 0 best solutions below