Skip to content

Commit

Permalink
Swap Stamen tiles for alternatives. Fix #313 (#314)
Browse files Browse the repository at this point in the history
  • Loading branch information
darribas authored Dec 14, 2023
1 parent ce016b8 commit d709b61
Show file tree
Hide file tree
Showing 4 changed files with 122 additions and 98 deletions.
24 changes: 12 additions & 12 deletions notebooks/06_spatial_autocorrelation.ipynb

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions notebooks/06_spatial_autocorrelation.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ jupyter:
extension: .md
format_name: markdown
format_version: '1.3'
jupytext_version: 1.14.5
jupytext_version: 1.15.2
kernelspec:
display_name: Python 3 (ipykernel)
display_name: GDS-10.0
language: python
name: python3
name: gds
---

```python tags=["remove-cell"]
Expand Down Expand Up @@ -111,7 +111,7 @@ db.plot(
contextily.add_basemap(
ax,
crs=db.crs,
source=contextily.providers.Stamen.TerrainBackground,
source=contextily.providers.Esri.WorldTerrain,
)
ax.set_axis_off()
```
Expand Down Expand Up @@ -190,7 +190,7 @@ ax1.set_title("% Leave")
contextily.add_basemap(
ax1,
crs=db.crs,
source=contextily.providers.Stamen.TerrainBackground,
source=contextily.providers.Esri.WorldTerrain,
)

db.plot(
Expand All @@ -209,7 +209,7 @@ ax2.set_title("% Leave - Spatial Lag")
contextily.add_basemap(
ax2,
crs=db.crs,
source=contextily.providers.Stamen.TerrainBackground,
source=contextily.providers.Esri.WorldTerrain,
)

plt.show()
Expand Down
166 changes: 95 additions & 71 deletions notebooks/12_feature_engineering.ipynb

Large diffs are not rendered by default.

18 changes: 9 additions & 9 deletions notebooks/12_feature_engineering.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ jupyter:
extension: .md
format_name: markdown
format_version: '1.3'
jupytext_version: 1.14.5
jupytext_version: 1.15.2
kernelspec:
display_name: Python 3 (ipykernel)
display_name: GDS-10.0
language: python
name: python3
name: gds
---

```python tags=["remove-cell"]
Expand Down Expand Up @@ -132,11 +132,11 @@ f, ax = plt.subplots(1, figsize=(12, 12))
airbnbs.plot(ax=ax, marker=".")
# Plot POIs in red
pois.plot(ax=ax, color="r")
# Add Stamen's Toner basemap
# Add Carto's Voyager basemap
contextily.add_basemap(
ax,
crs=airbnbs.crs.to_string(),
source=contextily.providers.Stamen.Toner,
source=contextily.providers.CartoDB.Voyager,
)
# Remove axes
ax.set_axis_off()
Expand Down Expand Up @@ -247,7 +247,7 @@ airbnbs_w_counts.plot(
contextily.add_basemap(
ax,
crs=airbnbs_albers.crs.to_string(),
source=contextily.providers.Stamen.Toner,
source=contextily.providers.CartoDB.Voyager,
)
# Remove axes
ax.set_axis_off();
Expand Down Expand Up @@ -330,11 +330,11 @@ airbnbs.join(
alpha=0.5,
ax=ax,
)
# Add Stamen's terrain basemap
# Add Esri's terrain basemap
contextily.add_basemap(
ax,
crs=airbnbs.crs.to_string(),
source=contextily.providers.Stamen.TerrainBackground,
source=contextily.providers.Esri.WorldTerrain,
alpha=0.5,
)
# Remove axes
Expand Down Expand Up @@ -417,7 +417,7 @@ two_bed_homes.plot(ax=ax, color="red")
contextily.add_basemap(
ax,
crs=two_bed_homes.crs.to_string(),
source=contextily.providers.Stamen.TonerBackground,
source=contextily.providers.CartoDB.VoyagerNoLabels,
)
# Remove axes
ax.set_axis_off();
Expand Down

0 comments on commit d709b61

Please sign in to comment.